]>
Commit | Line | Data |
---|---|---|
9daed0b5 GA |
1 | 2023-11-02 Martin Uecker <uecker@tugraz.at> |
2 | ||
3 | PR c/112347 | |
4 | * c-typeck.cc (convert_for_assignment): Add missing check. | |
5 | ||
c73d2d49 GA |
6 | 2023-11-01 Martin Uecker <uecker@tugraz.at> |
7 | ||
8 | PR c/71219 | |
9 | * c-typeck.cc (convert_for_assignment): Add warning. | |
10 | ||
ecca503b GA |
11 | 2023-10-26 liuhongt <hongtao.liu@intel.com> |
12 | ||
13 | * c-typeck.cc (build_vec_cmp): Pass type of arg0 to | |
14 | truth_type_for. | |
15 | ||
f75fc1f0 GA |
16 | 2023-10-25 Thomas Schwinge <thomas@codesourcery.com> |
17 | ||
18 | * c-parser.cc (c_parser_omp_clause_name): Return | |
19 | 'PRAGMA_OACC_CLAUSE_SELF' for "self". | |
20 | (c_parser_oacc_data_clause, OACC_UPDATE_CLAUSE_MASK): Adjust. | |
21 | (c_parser_oacc_all_clauses): Remove 'bool compute_p' formal | |
22 | parameter, and instead locally determine whether we're called for | |
23 | an OpenACC compute construct or OpenACC 'update' directive. | |
24 | (c_parser_oacc_compute): Adjust. | |
25 | ||
26 | 2023-10-25 Chung-Lin Tang <cltang@codesourcery.com> | |
27 | ||
28 | * c-parser.cc (c_parser_oacc_compute_clause_self): New function. | |
29 | (c_parser_oacc_all_clauses): Add new 'bool compute_p = false' | |
30 | parameter, add parsing of self clause when compute_p is true. | |
31 | (OACC_KERNELS_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_SELF. | |
32 | (OACC_PARALLEL_CLAUSE_MASK): Likewise, | |
33 | (OACC_SERIAL_CLAUSE_MASK): Likewise. | |
34 | (c_parser_oacc_compute): Adjust call to c_parser_oacc_all_clauses to | |
35 | set compute_p argument to true. | |
36 | * c-typeck.cc (c_finish_omp_clauses): Add OMP_CLAUSE_SELF case. | |
37 | ||
6f684dd2 GA |
38 | 2023-10-20 Florian Weimer <fweimer@redhat.com> |
39 | ||
40 | PR c/109827 | |
41 | PR other/44209 | |
42 | * c-typeck.cc (build_conditional_expr): Use OPT_Wint_conversion | |
43 | for pointer/integer mismatch warnings. | |
44 | ||
45 | 2023-10-20 Florian Weimer <fweimer@redhat.com> | |
46 | ||
47 | PR c/109826 | |
48 | PR other/44209 | |
49 | * c-typeck.cc (build_conditional_expr): Use | |
50 | OPT_Wincompatible_pointer_types for pointer mismatches. | |
51 | Emit location information for the operand. | |
52 | ||
c85f7481 GA |
53 | 2023-10-19 Andrew Pinski <pinskia@gmail.com> |
54 | ||
55 | PR c/100532 | |
56 | * c-typeck.cc (convert_argument): After erroring out | |
57 | about an incomplete type return error_mark_node. | |
58 | ||
59 | 2023-10-19 Andrew Pinski <pinskia@gmail.com> | |
60 | ||
61 | PR c/104822 | |
62 | * c-typeck.cc (convert_for_assignment): Check for null pointer | |
63 | before warning about an incompatible scalar storage order. | |
64 | ||
0308461d GA |
65 | 2023-10-18 Andrew Pinski <pinskia@gmail.com> |
66 | ||
67 | PR c/101364 | |
68 | * c-decl.cc (diagnose_arglist_conflict): Test for | |
69 | error mark before calling of c_type_promotes_to. | |
70 | ||
71 | 2023-10-18 Andrew Pinski <pinskia@gmail.com> | |
72 | ||
73 | PR c/101285 | |
74 | * c-typeck.cc (c_safe_arg_type_equiv_p): Return true for error | |
75 | operands early. | |
76 | ||
fb69acff GA |
77 | 2023-10-17 Martin Uecker <uecker@tugraz.at> |
78 | ||
79 | PR c/111708 | |
80 | * c-decl.cc (grokdeclarator): Add error. | |
81 | ||
96557ee6 GA |
82 | 2023-10-03 David Malcolm <dmalcolm@redhat.com> |
83 | ||
84 | * c-objc-common.cc (c_tree_printer): Update for "m_" prefixes to | |
85 | text_info fields. | |
86 | ||
125781fb GA |
87 | 2023-09-30 Eugene Rozenfeld <erozen@microsoft.com> |
88 | ||
89 | * Make-lang.in: Make create_fdas_for_cc1 target not .PHONY | |
90 | ||
4907d220 GA |
91 | 2023-09-20 Jakub Jelinek <jakub@redhat.com> |
92 | ||
93 | * c-parser.cc (c_parser_postfix_expression_after_primary): Parse | |
94 | __builtin_classify_type call with typename as argument. | |
95 | ||
590a8bec GA |
96 | 2023-09-19 Richard Biener <rguenther@suse.de> |
97 | ||
98 | PR c/111468 | |
99 | * gimple-parser.cc (c_parser_gimple_binary_expression): Handle __LTGT. | |
100 | ||
101 | 2023-09-19 Richard Biener <rguenther@suse.de> | |
102 | ||
103 | PR c/111468 | |
104 | * gimple-parser.cc (c_parser_gimple_binary_expression): Add | |
105 | return type argument. | |
106 | (c_parser_gimple_statement): Adjust. | |
107 | (c_parser_gimple_paren_condition): Likewise. | |
108 | (c_parser_gimple_binary_expression): Use passed in return type, | |
109 | add support for - as POINTER_DIFF_EXPR, __UN{LT,LE,GT,GE,EQ}, | |
110 | __UNORDERED and __ORDERED. | |
111 | ||
a1c20158 GA |
112 | 2023-09-12 Tobias Burnus <tobias@codesourcery.com> |
113 | ||
114 | * c-parser.cc (struct c_omp_loc_tree): New. | |
115 | (c_check_omp_allocate_allocator_r): New; checking moved from ... | |
116 | (c_parser_omp_allocate): ... here. Call it via walk_tree. Avoid | |
117 | ICE with tree_to_shwi for invalid too-large value. | |
118 | ||
119 | 2023-09-12 Tobias Burnus <tobias@codesourcery.com> | |
120 | ||
121 | * c-parser.cc (c_parser_omp_construct): Move call to | |
122 | c_parser_omp_allocate to ... | |
123 | (c_parser_pragma): ... here. | |
124 | (c_parser_omp_allocate): Avoid ICE is allocator could not be | |
125 | parsed; set 'omp allocate' attribute for stack/automatic variables | |
126 | and only reject static variables; add several additional | |
127 | restriction checks. | |
128 | * c-tree.h (c_mark_decl_jump_unsafe_in_current_scope): New prototype. | |
129 | * c-decl.cc (decl_jump_unsafe): Return true for omp-allocated decls. | |
130 | (c_mark_decl_jump_unsafe_in_current_scope): New. | |
131 | (warn_about_goto, c_check_switch_jump_warnings): Add error for | |
132 | omp-allocated decls. | |
133 | ||
134 | 2023-09-12 Martin Uecker <uecker@tugraz.at> | |
135 | ||
136 | * c-typeck.cc (struct comptypes_data): Add structure. | |
137 | (tagged_types_tu_compatible_p, | |
138 | function_types_compatible_p, type_lists_compatible_p, | |
139 | comptypes_internal): Add structure to interface, change | |
140 | return type to bool, and adapt calls. | |
141 | (comptarget_types): Change return type too bool. | |
142 | (comptypes, comptypes_check_enum_int, | |
143 | comptypes_check_different_types): Adapt calls. | |
144 | ||
a134b6ce GA |
145 | 2023-09-06 Jakub Jelinek <jakub@redhat.com> |
146 | ||
147 | PR c/102989 | |
148 | * c-decl.cc (finish_declspecs): Emit pedwarn_c11 on _BitInt. | |
149 | * c-typeck.cc (c_common_type): Emit sorry for common type between | |
150 | _Complex integer and larger _BitInt and return the _Complex integer. | |
151 | ||
152 | 2023-09-06 Jakub Jelinek <jakub@redhat.com> | |
153 | ||
154 | PR c/102989 | |
155 | * c-convert.cc (c_convert): Handle BITINT_TYPE like INTEGER_TYPE. | |
156 | * c-decl.cc (check_bitfield_type_and_width): Allow BITINT_TYPE | |
157 | bit-fields. | |
158 | (finish_struct): Prefer to use BITINT_TYPE for BITINT_TYPE bit-fields | |
159 | if possible. | |
160 | (declspecs_add_type): Formatting fixes. Handle cts_bitint. Adjust | |
161 | for added union in *specs. Handle RID_BITINT. | |
162 | (finish_declspecs): Handle cts_bitint. Adjust for added union | |
163 | in *specs. | |
164 | * c-parser.cc (c_keyword_starts_typename, c_token_starts_declspecs, | |
165 | c_parser_declspecs, c_parser_gnu_attribute_any_word): Handle | |
166 | RID_BITINT. | |
167 | (c_parser_omp_clause_schedule): Handle BITINT_TYPE like INTEGER_TYPE. | |
168 | * c-tree.h (enum c_typespec_keyword): Mention _BitInt in comment. | |
169 | Add cts_bitint enumerator. | |
170 | (struct c_declspecs): Move int_n_idx and floatn_nx_idx into a union | |
171 | and add bitint_prec there as well. | |
172 | * c-typeck.cc (c_common_type, comptypes_internal): | |
173 | Handle BITINT_TYPE. | |
174 | (perform_integral_promotions): Promote BITINT_TYPE bit-fields to | |
175 | their declared type. | |
176 | (build_array_ref, build_unary_op, build_conditional_expr, | |
177 | build_c_cast, convert_for_assignment, digest_init, build_binary_op): | |
178 | Handle BITINT_TYPE. | |
179 | * c-fold.cc (c_fully_fold_internal): Handle BITINT_TYPE like | |
180 | INTEGER_TYPE. | |
181 | * c-aux-info.cc (gen_type): Handle BITINT_TYPE. | |
182 | ||
183 | 2023-09-06 Jakub Jelinek <jakub@redhat.com> | |
184 | ||
185 | * c-decl.cc (declspecs_add_type): Use pedwarn_c11 rather than pedwarn | |
186 | for _FloatN{,x} diagnostics and append " before C2X" to the diagnostic | |
187 | text. | |
188 | ||
4388bc82 GA |
189 | 2023-09-05 Tobias Burnus <tobias@codesourcery.com> |
190 | ||
191 | * c-parser.cc (c_parser_omp_clause_allocate): Handle | |
192 | error_mark_node. | |
193 | ||
b8863640 GA |
194 | 2023-08-25 Sandra Loosemore <sandra@codesourcery.com> |
195 | ||
196 | * c-parser.cc (struct c_parser): Add omp_for_parse_state field. | |
197 | (struct omp_for_parse_data): New. | |
198 | (check_omp_intervening_code): New. | |
199 | (add_structured_block_stmt): New. | |
200 | (c_parser_compound_statement_nostart): Recognize intervening code, | |
201 | nested loops, and other things that need special handling in | |
202 | OpenMP loop constructs. | |
203 | (c_parser_while_statement): Error on loop in intervening code. | |
204 | (c_parser_do_statement): Likewise. | |
205 | (c_parser_for_statement): Likewise. | |
206 | (c_parser_postfix_expression_after_primary): Error on calls to | |
207 | the OpenMP runtime in intervening code. | |
208 | (c_parser_pragma): Error on OpenMP pragmas in intervening code. | |
209 | (c_parser_omp_loop_nest): New. | |
210 | (c_parser_omp_for_loop): Rewrite to use recursive descent, calling | |
211 | c_parser_omp_loop_nest to do the heavy lifting. | |
212 | ||
6d47c9b4 GA |
213 | 2023-08-24 Richard Sandiford <richard.sandiford@arm.com> |
214 | ||
215 | * c-parser.cc (c_parser_std_attribute): Conditionally allow | |
216 | two colons to be used in place of ::. | |
217 | (c_parser_std_attribute_list): New function, split out from... | |
218 | (c_parser_std_attribute_specifier): ...here. Allow the attribute-list | |
219 | to start with __extension__. When it does, also allow two colons | |
220 | to be used in place of ::. | |
221 | ||
6cd85273 GA |
222 | 2023-08-22 Tobias Burnus <tobias@codesourcery.com> |
223 | ||
224 | * c-parser.cc (c_parser_omp_clause_defaultmap): Parse | |
225 | 'all' as category. | |
226 | ||
1eb2433f GA |
227 | 2023-08-17 Jose E. Marchesi <jose.marchesi@oracle.com> |
228 | ||
229 | PR c/106537 | |
230 | * c-typeck.cc (build_binary_op): Warning on comparing distinct | |
231 | pointer types only when -Wcompare-distinct-pointer-types. | |
232 | ||
b01e96f8 GA |
233 | 2023-08-15 Chung-Lin Tang <cltang@codesourcery.com> |
234 | Thomas Schwinge <thomas@codesourcery.com> | |
235 | ||
236 | * c-parser.cc (OACC_DATA_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_DEFAULT. | |
237 | ||
886afed6 GA |
238 | 2023-08-11 Jakub Jelinek <jakub@redhat.com> |
239 | ||
240 | * c-parser.cc (c_parser_typeof_specifier): Handle | |
241 | __typeof_unqual and __typeof_unqual__ as !is_std. | |
242 | ||
243 | 2023-08-11 Martin Uecker <uecker@tugraz.at> | |
244 | ||
245 | PR c/84510 | |
246 | * c-typeck.cc (build_c_cast): Add warning. | |
247 | ||
87b0749c GA |
248 | 2023-08-05 Martin Uecker <uecker@tugraz.at> |
249 | ||
250 | * c-parser.cc (c_parser_generic_selection): Inhibit evaluation | |
251 | warnings branches that are known not be taken during parsing. | |
252 | ||
5b42ee2c GA |
253 | 2023-08-04 Tamar Christina <tamar.christina@arm.com> |
254 | ||
255 | * c-parser.cc (c_parser_while_statement, c_parser_do_statement, | |
256 | c_parser_for_statement, c_parser_statement_after_labels, | |
257 | c_parse_pragma_novector, c_parser_pragma): Wire through novector and | |
258 | default to false. | |
259 | ||
4297a08e GA |
260 | 2023-08-02 Eric Feng <ef2648@columbia.edu> |
261 | ||
262 | PR analyzer/107646 | |
263 | * c-parser.cc: New functions on stashing values for the | |
264 | analyzer. | |
265 | ||
cf58b896 GA |
266 | 2023-08-01 Lewis Hyatt <lhyatt@gmail.com> |
267 | ||
268 | * c-parser.cc (pragma_lex_discard_to_eol): New function. | |
269 | (c_init_preprocess): New function. | |
270 | ||
a2f31d79 GA |
271 | 2023-07-31 Hamza Mahfooz <someguy@effective-light.com> |
272 | ||
273 | PR c/65213 | |
274 | * c-decl.cc (start_decl): Handle | |
275 | -Wmissing-variable-declarations. | |
276 | ||
277 | 2023-07-31 Chung-Lin Tang <cltang@codesourcery.com> | |
278 | ||
279 | * c-parser.cc (c_parser_oacc_host_data): Add checking requiring OpenACC | |
280 | host_data construct to have an use_device clause. | |
281 | ||
14bfda60 GA |
282 | 2023-06-29 Qing Zhao <qing.zhao@oracle.com> |
283 | ||
284 | PR c/77650 | |
285 | * c-decl.cc (finish_struct): Issue warnings for new option. | |
286 | ||
287 | 2023-06-29 Qing Zhao <qing.zhao@oracle.com> | |
288 | ||
289 | * c-decl.cc (finish_struct): Set TYPE_INCLUDES_FLEXARRAY for | |
290 | struct/union type. | |
291 | ||
292 | 2023-06-29 Richard Biener <rguenther@suse.de> | |
293 | ||
294 | PR c/110454 | |
295 | * c-typeck.cc (convert_argument): Sink formal_prec compute | |
296 | to where TYPE_PRECISION is valid to use. | |
297 | ||
298 | 2023-06-29 Eugene Rozenfeld <erozen@microsoft.com> | |
299 | ||
300 | * Make-lang.in: Pass correct stage cc1 when processing | |
301 | profile data collected while building target libraries | |
302 | ||
f10a4ce0 GA |
303 | 2023-06-16 David Malcolm <dmalcolm@redhat.com> |
304 | ||
305 | PR c/107583 | |
306 | * c-parser.cc (c_parser_declspecs): Add hints to "unknown type | |
307 | name" error. | |
308 | ||
9d250bdb GA |
309 | 2023-06-12 Tobias Burnus <tobias@codesourcery.com> |
310 | ||
311 | * c-parser.cc (c_parser_omp_clause_map): Reword error message for | |
312 | clearness especially with 'omp target (enter/exit) data.' | |
313 | ||
4f0d4825 GA |
314 | 2023-06-06 Kwok Cheung Yeung <kcy@codesourcery.com> |
315 | Tobias Burnus <tobias@codesourcery.com> | |
316 | ||
317 | * c-parser.cc (c_parser_omp_clause_defaultmap, | |
318 | c_parser_omp_clause_map): Parse 'present'. | |
319 | (c_parser_omp_clause_to, c_parser_omp_clause_from): Remove. | |
320 | (c_parser_omp_clause_from_to): New; parse to/from clauses with | |
321 | optional present modifer. | |
322 | (c_parser_omp_all_clauses): Update call. | |
323 | (c_parser_omp_target_data, c_parser_omp_target_enter_data, | |
324 | c_parser_omp_target_exit_data): Handle new map enum values | |
325 | for 'present' mapping. | |
326 | ||
df2762ac GA |
327 | 2023-05-30 Tobias Burnus <tobias@codesourcery.com> |
328 | ||
329 | PR c/109999 | |
330 | * c-parser.cc (c_parser_oacc_all_clauses, | |
331 | c_parser_omp_all_clauses): Improve error wording. | |
332 | ||
03c7c418 GA |
333 | 2023-05-23 Martin Uecker <uecker@tugraz.at> |
334 | ||
335 | PR c/109450 | |
336 | * c-decl.cc (add_decl_expr): New function. | |
337 | (grokdeclarator): Add decl expr for size expression in | |
338 | types pointed to by parameters declared as arrays. | |
339 | ||
340 | 2023-05-23 Martin Uecker <uecker@tugraz.at> | |
341 | ||
342 | PR c/70418 | |
343 | PR c/106465 | |
344 | PR c/107557 | |
345 | PR c/108423 | |
346 | * c-decl.cc (start_decl): Make sure size expression are | |
347 | evaluated only in correct context. | |
348 | (grokdeclarator): Size expression in fields may need a bind | |
349 | expression, make sure DECL_EXPR is always created. | |
350 | (grokfield, declspecs_add_type): Pass along size expressions. | |
351 | (finish_struct): Remove unneeded DECL_EXPR. | |
352 | (start_function): Evaluate size expressions for nested functions. | |
353 | * c-parser.cc (c_parser_struct_declarations, | |
354 | c_parser_struct_or_union_specifier): Pass along size expressions. | |
355 | (c_parser_declaration_or_fndef): Evaluate size expression. | |
356 | (c_parser_objc_at_property_declaration, | |
357 | c_parser_objc_class_instance_variables): Adapt. | |
358 | * c-tree.h (grokfield): Adapt declaration. | |
359 | ||
5df01f89 GA |
360 | 2023-05-19 Martin Uecker <uecker@tugraz.at> |
361 | ||
362 | * c-decl.cc (set_type_context): Remove. | |
363 | (pop_scope, diagnose_mismatched_decls, pushdecl): | |
364 | Remove dead code. | |
365 | * c-typeck.cc (comptypes_internal): Remove dead code. | |
366 | (same_translation_unit_p): Remove. | |
367 | (tagged_types_tu_compatible_p): Some fixes. | |
368 | ||
369 | 2023-05-19 Joseph Myers <joseph@codesourcery.com> | |
370 | ||
371 | * c-decl.cc (diagnose_mismatched_decls): Do not handle | |
372 | thread-local declarations as tentative definitions for C2x. | |
373 | (finish_decl): Do not allow thread-local definition with | |
374 | incomplete type for C2x. | |
375 | ||
b2776076 GA |
376 | 2023-05-18 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> |
377 | ||
378 | * c-convert.cc (c_convert): Ditto. | |
379 | * c-decl.cc (merge_decls): Ditto. | |
380 | * c-parser.cc (c_parser_omp_clause_reduction): Ditto. | |
381 | (c_parser_omp_declare_reduction): Ditto. | |
382 | * c-typeck.cc (build_component_ref): Ditto. | |
383 | (convert_argument): Ditto. | |
384 | (pointer_diff): Ditto. | |
385 | (build_unary_op): Ditto. | |
386 | (build_c_cast): Ditto. | |
387 | (build_modify_expr): Ditto. | |
388 | (store_init_value): Ditto. | |
389 | (constexpr_init_fits_real_type): Ditto. | |
390 | (check_constexpr_init): Ditto. | |
391 | (c_finish_return): Ditto. | |
392 | (handle_omp_array_sections_1): Ditto. | |
393 | (c_finish_omp_clauses): Ditto. | |
394 | * gimple-parser.cc (c_finish_gimple_return): Ditto. | |
395 | ||
0d566057 GA |
396 | 2023-05-16 Joseph Myers <joseph@codesourcery.com> |
397 | ||
398 | * c-decl.cc (check_for_loop_decls): Use pedwarn_c11 for | |
399 | diagnostics. | |
400 | ||
3427b51b GA |
401 | 2023-05-15 Joseph Myers <joseph@codesourcery.com> |
402 | ||
403 | * c-decl.cc (grokdeclarator): Ignore _Atomic on function return | |
404 | type for C2x. | |
405 | ||
4d68c7f7 GA |
406 | 2023-04-30 Andrew Pinski <apinski@marvell.com> |
407 | ||
408 | * c-typeck.cc (process_init_element): Print out array type | |
409 | for excessive elements. | |
410 | ||
411 | 2023-04-30 Andrew Pinski <apinski@marvell.com> | |
412 | ||
413 | PR c/107926 | |
414 | * c-typeck.cc (process_init_element): Move the check | |
415 | for string cst until after the error message. | |
416 | ||
50205195 GA |
417 | 2023-04-28 Eugene Rozenfeld <erozen@microsoft.com> |
418 | ||
419 | * Make-lang.in: Merge perf data collected when compiling cc1 and runtime libraries | |
420 | ||
32a98ccd GA |
421 | 2023-04-27 Jakub Jelinek <jakub@redhat.com> |
422 | ||
423 | PR c/109409 | |
424 | * c-parser.cc (c_parser_initializer): Move diagnostics about | |
425 | initialization of variable sized object with non-empty initializer | |
426 | after c_parser_expr_no_commas call and ret.set_error (); after it. | |
427 | ||
428 | 2023-04-27 Jakub Jelinek <jakub@redhat.com> | |
429 | ||
430 | PR c/107682 | |
431 | PR c/109412 | |
432 | * c-typeck.cc (pop_init_level): If constructor_type is FUNCTION_TYPE, | |
433 | reject empty initializer as invalid. | |
434 | ||
4a3dbcbd GA |
435 | 2023-04-26 Richard Biener <rguenther@suse.de> |
436 | ||
437 | * gimple-parser.cc (c_parser_parse_gimple_body): Avoid | |
438 | last_stmt. | |
439 | ||
49cea02d GA |
440 | 2023-04-25 Tobias Burnus <tobias@codesourcery.com> |
441 | ||
442 | * c-parser.cc (c_parser_omp_scan_loop_body): Handle | |
443 | zero exec statements before/after 'omp scan'. | |
444 | ||
ce4e4f37 GA |
445 | 2023-04-20 Jakub Jelinek <jakub@redhat.com> |
446 | ||
447 | PR c/107041 | |
448 | * c-decl.cc (diagnose_mismatched_decls): Avoid -Wenum-int-mismatch | |
449 | warning on acc_on_device declaration. | |
450 | ||
579cdc1e GA |
451 | 2023-03-28 David Malcolm <dmalcolm@redhat.com> |
452 | ||
453 | PR c/107002 | |
454 | * c-typeck.cc (parser_build_binary_op): Update for new param of | |
455 | check_for_xor_used_as_pow. | |
456 | ||
c8065441 GA |
457 | 2023-03-10 Jakub Jelinek <jakub@redhat.com> |
458 | ||
459 | PR c/108079 | |
460 | * c-decl.cc (pop_scope): Suppress OPT_Wunused_variable warning | |
461 | after diagnosing it. | |
462 | ||
6f9e2f14 GA |
463 | 2023-02-28 Jakub Jelinek <jakub@redhat.com> |
464 | ||
465 | PR sanitizer/108894 | |
466 | * c-decl.cc (strict_flex_array_level_of): Move to c-common.cc | |
467 | and rename to c_strict_flex_array_level_of. | |
468 | (is_flexible_array_member_p): Adjust caller. | |
469 | ||
0263e9d5 GA |
470 | 2023-02-18 Martin Uecker <uecker@tugraz.at> |
471 | ||
472 | PR c/108375 | |
473 | * c-decl.cc (decl_jump_unsafe): Use c_type_variably_modified_p. | |
474 | (diagnose_mismatched_decl): Dito. | |
475 | (warn_about_goto): Dito: | |
476 | (c_check_switch_jump_warnings): Dito. | |
477 | (finish_decl): Dito. | |
478 | (finish_struct): Dito. | |
479 | (grokdeclarator): Set C_TYPE_VARIABLY_MODIFIED. | |
480 | (finish_struct): Set C_TYPE_VARIABLY_MODIFIED. | |
481 | * c-objc-common.cc (c_var_mod_p): New function. | |
482 | (c_var_unspec_p): Remove. | |
483 | * c-objc-common.h: Set lang hook. | |
484 | * c-parser.cc (c_parser_declararion_or_fndef): Use c_type_variably_modified_p. | |
485 | (c_parser_typeof_specifier): Dito. | |
486 | (c_parser_has_attribute_expression): Dito. | |
487 | (c_parser_generic_selection): Dito. | |
488 | * c-tree.h: Define C_TYPE_VARIABLY_MODIFIED and define c_var_mode_p. | |
489 | * c-typeck.cc: Remove c_vla_mod_p and use C_TYPE_VARIABLY_MODIFIED. | |
490 | ||
88cc4495 GA |
491 | 2023-02-16 Patrick Palka <ppalka@redhat.com> |
492 | ||
493 | * c-parser.h: Mechanically drop static from static inline | |
494 | functions via s/^static inline/inline/g. | |
495 | ||
d7a47ed1 GA |
496 | 2023-02-10 Joseph Myers <joseph@codesourcery.com> |
497 | ||
498 | * c-convert.cc (c_convert): Allow conversion of a null pointer | |
499 | constant to nullptr_t. | |
500 | * c-typeck.cc (null_pointer_constant_p): Remove static. | |
501 | (convert_for_assignment): Allow conversion of a null pointer | |
502 | constant to nullptr_t. | |
503 | (digest_init): Handle NULLPTR_TYPE among scalar conversions. | |
504 | * c-tree.h (null_pointer_constant_p): Declare. | |
505 | ||
e92e2c96 GA |
506 | 2023-02-09 Tobias Burnus <tobias@codesourcery.com> |
507 | ||
508 | * c-parser.cc (c_parser_omp_allocate): Parse align | |
509 | clause and check for restrictions. | |
510 | ||
f6fc79d0 GA |
511 | 2023-02-08 Joseph Myers <joseph@codesourcery.com> |
512 | ||
513 | * c-typeck.cc (check_constexpr_init): Remove argument | |
514 | null_pointer_constant. Only check pointer initializers for being | |
515 | null. | |
516 | (digest_init): Update calls to check_constexpr_init. | |
517 | ||
a37a0cb3 GA |
518 | 2023-02-02 Joseph Myers <joseph@codesourcery.com> |
519 | ||
520 | * c-typeck.cc (build_binary_op): Allow comparisons between | |
521 | pointers and nullptr_t values that are not null pointer constants. | |
522 | ||
523 | 2023-02-02 Joseph Myers <joseph@codesourcery.com> | |
524 | ||
525 | * c-typeck.cc: Include "realmpfr.h". | |
526 | (constexpr_init_fits_real_type): Do not allow signaling NaN | |
527 | conversions to different types with the same mode. Handle | |
528 | conversions from binary to decimal types. | |
529 | (check_constexpr_init): Do not disallow real initializers for | |
530 | complex types. Do not disallow binary initializers for decimal | |
531 | floating types. | |
532 | ||
317525b0 GA |
533 | 2023-01-31 Marek Polacek <polacek@redhat.com> |
534 | ||
535 | PR c++/107593 | |
536 | PR c++/108597 | |
537 | * c-objc-common.cc (instantiation_dependent_expression_p): New. | |
538 | ||
338eb0f0 GA |
539 | 2023-01-27 Joseph Myers <joseph@codesourcery.com> |
540 | ||
541 | * c-parser.cc (c_parser_declaration_or_fndef): Do not allow braces | |
542 | around auto initializer. | |
543 | ||
f457a62e GA |
544 | 2023-01-16 Jakub Jelinek <jakub@redhat.com> |
545 | ||
546 | PR c++/105593 | |
547 | * c-parser.cc (c_parser_initializer): Check warning_enabled_at | |
548 | at the DECL_SOURCE_LOCATION (decl) for OPT_Winit_self instead | |
549 | of warn_init_self. | |
550 | ||
5013c3bb GA |
551 | 2023-01-14 Jakub Jelinek <jakub@redhat.com> |
552 | ||
553 | PR c++/108365 | |
554 | * c-typeck.cc (build_binary_op): Use may_shorten_divmod for integral | |
555 | division or modulo. | |
556 | ||
557 | 2023-01-13 Qing Zhao <qing.zhao@oracle.com> | |
558 | ||
559 | * c-decl.cc (strict_flex_array_level_of): ... here. | |
560 | ||
81ed98bc GA |
561 | 2023-01-11 Jakub Jelinek <jakub@redhat.com> |
562 | ||
563 | PR c/105972 | |
564 | * c-parser.cc (c_parser_declaration_or_fndef): Disable debug non-bind | |
565 | markers for K&R function parameter declarations of nested functions. | |
566 | ||
84723aca GA |
567 | 2023-01-09 Joseph Myers <joseph@codesourcery.com> |
568 | ||
569 | * c-decl.cc (build_compound_literal): Call record_inline_static. | |
570 | ||
d808db1f GA |
571 | 2023-01-06 Joseph Myers <joseph@codesourcery.com> |
572 | ||
573 | * c-parser.cc (c_parser_postfix_expression): Handle integer | |
574 | generic arguments to functions passed to __builtin_tgmath as | |
575 | _Float32x if any argument has _FloatNx or _Complex _FloatNx type. | |
576 | Do not handle integer arguments to some narrowing functions as | |
577 | _Float64. | |
578 | ||
d2ef2327 GA |
579 | 2022-12-19 Jakub Jelinek <jakub@redhat.com> |
580 | ||
581 | PR c/108043 | |
582 | * c-parser.cc (c_parser_postfix_expression_after_paren_type): Diagnose | |
583 | compound literals with function type. | |
584 | ||
4bc2d9f6 GA |
585 | 2022-12-07 Joseph Myers <joseph@codesourcery.com> |
586 | ||
587 | * c-decl.cc (declspecs_add_type, declspecs_add_scspec): Check for | |
588 | auto, constexpr and a type used together. | |
589 | ||
3fe66f7f GA |
590 | 2022-12-06 Qing Zhao <qing.zhao@oracle.com> |
591 | ||
592 | * c-decl.cc (is_flexible_array_member_p): Call new function | |
593 | strict_flex_array_level_of. | |
594 | ||
9a1b4f1d GA |
595 | 2022-11-24 Florian Weimer <fweimer@redhat.com> |
596 | ||
597 | PR c/107805 | |
598 | * c-decl.cc (declspecs_add_type): Propagate error_mark_bode | |
599 | from type to specs. | |
600 | ||
add89840 GA |
601 | 2022-11-17 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> |
602 | ||
603 | * c-decl.cc (start_function): Set the result decl source | |
604 | location to the location of the typespec. | |
605 | ||
606 | 2022-11-17 David Malcolm <dmalcolm@redhat.com> | |
607 | ||
608 | PR analyzer/107711 | |
609 | * c-parser.cc (ana::c_translation_unit::consider_macro): Pass NULL | |
610 | to cpp_create_reader, rather than ident_hash, so that the new | |
611 | reader gets its own hash table. | |
612 | ||
cdc34229 GA |
613 | 2022-11-15 David Malcolm <dmalcolm@redhat.com> |
614 | ||
615 | PR analyzer/106302 | |
616 | * c-parser.cc: Include "analyzer/analyzer-language.h" and "toplev.h". | |
617 | (class ana::c_translation_unit): New. | |
618 | (c_parser_translation_unit): Call ana::on_finish_translation_unit. | |
619 | ||
30d77d49 GA |
620 | 2022-11-12 Joseph Myers <joseph@codesourcery.com> |
621 | ||
622 | * c-decl.cc (start_underspecified_init) | |
623 | (finish_underspecified_init): Handle name == NULL_TREE for | |
624 | compound literals. | |
625 | (merge_decls): Merge C_DECL_DECLARED_CONSTEXPR. | |
626 | (shadow_tag_warned): Check for constexpr. | |
627 | (start_decl): Add parameter do_push. | |
628 | (build_compound_literal): Set C_DECL_DECLARED_CONSTEXPR. | |
629 | (grokdeclarator): Handle constexpr. | |
630 | (finish_struct): Set C_TYPE_FIELDS_NON_CONSTEXPR. | |
631 | (declspecs_add_scspec): Handle constexpr. | |
632 | * c-parser.cc (c_token_starts_compound_literal) | |
633 | (c_token_starts_declspecs, c_parser_declaration_or_fndef) | |
634 | (c_parser_declspecs, c_parser_gnu_attribute_any_word) | |
635 | (c_parser_compound_literal_scspecs) | |
636 | (c_parser_postfix_expression_after_paren_type): Handle constexpr. | |
637 | Update calls to start_init. | |
638 | (c_parser_declaration_or_fndef, c_parser_initializer) | |
639 | (c_parser_initval): Pass true for new argument of | |
640 | convert_lvalue_to_rvalue. Call convert_lvalue_to_rvalue for | |
641 | constexpr compound literals. | |
642 | (c_parser_static_assert_declaration_no_semi) | |
643 | (c_parser_enum_specifier, c_parser_struct_declaration) | |
644 | (c_parser_alignas_specifier, c_parser_initelt, c_parser_label): | |
645 | Call convert_lvalue_to_rvalue on expressions required to be | |
646 | integer constant expressions. | |
647 | (c_parser_omp_declare_reduction): Update call to start_init. | |
648 | * c-tree.h (C_TYPE_FIELDS_NON_CONSTEXPR) | |
649 | (C_DECL_DECLARED_CONSTEXPR): New macros. | |
650 | (struct c_declspecs): Add constexpr_p. | |
651 | (start_decl, convert_lvalue_to_rvalue, start_init): Update | |
652 | prototypes. | |
653 | * c-typeck.cc (require_constant_value, require_constant_elements): | |
654 | Change to bool. | |
655 | (require_constexpr_value, maybe_get_constexpr_init) | |
656 | (constexpr_init_fits_real_type, check_constexpr_init): New. | |
657 | (convert_lvalue_to_rvalue): Add new parameter for_init. Call | |
658 | maybe_get_constexpr_init. | |
659 | (store_init_value): Update call to digest_init. | |
660 | (digest_init): Add parameters int_const_expr, arith_const_expr and | |
661 | require_constexpr. Check constexpr initializers. | |
662 | (constructor_top_level): Remove. | |
663 | (struct initializer_stack): Remove top_level. Add | |
664 | require_constexpr_value. | |
665 | (start_init): Remove parameter top_level. Add parameters | |
666 | init_require_constant and init_require_constexpr. Save | |
667 | require_constexpr_value on stack. | |
668 | (pop_init_level): Use a null pointer constant for zero initializer | |
669 | of pointer initialized with {}. | |
670 | (output_init_element): Update call to digest_init. Avoid passing | |
671 | null pointer constants of pointer type through digest_init a | |
672 | second time when initializing a constexpr object. | |
673 | ||
d29260ce GA |
674 | 2022-11-03 Joseph Myers <joseph@codesourcery.com> |
675 | ||
676 | * c-decl.cc (in_underspecified_init, start_underspecified_init) | |
677 | (finish_underspecified_init): New. | |
678 | (shadow_tag_warned, parser_xref_tag, start_struct, start_enum): | |
679 | Give errors inside initializers of underspecified declarations. | |
680 | (grokdeclarator): Handle (erroneous) case of C2X auto on a | |
681 | parameter. | |
682 | (declspecs_add_type): Handle c2x_auto_p case. | |
683 | (declspecs_add_scspec): Handle auto possibly setting c2x_auto_p in | |
684 | C2X mode. | |
685 | (finish_declspecs): Handle c2x_auto_p. | |
686 | * c-parser.cc (c_parser_declaration_or_fndef): Handle C2X auto. | |
687 | * c-tree.h (C_DECL_UNDERSPECIFIED): New macro. | |
688 | (struct c_declspecs): Add c2x_auto_p. | |
689 | (start_underspecified_init, finish_underspecified_init): New | |
690 | prototypes. | |
691 | * c-typeck.cc (build_external_ref): Give error for underspecified | |
692 | declaration referenced in its initializer. | |
693 | ||
3055829a GA |
694 | 2022-10-28 Joseph Myers <joseph@codesourcery.com> |
695 | ||
696 | * c-decl.cc (grokdeclarator): Pass | |
697 | arg_info->no_named_args_stdarg_p to build_function_type. | |
698 | (grokparms): Check arg_info->no_named_args_stdarg_p before | |
699 | converting () to (void). | |
700 | (build_arg_info): Initialize no_named_args_stdarg_p. | |
701 | (get_parm_info): Set no_named_args_stdarg_p. | |
702 | (start_function): Pass TYPE_NO_NAMED_ARGS_STDARG_P to | |
703 | build_function_type. | |
704 | (store_parm_decls): Count (...) functions as prototyped. | |
705 | * c-parser.cc (c_parser_direct_declarator): Allow '...' after open | |
706 | parenthesis to start parameter list. | |
707 | (c_parser_parms_list_declarator): Always allow '...' with no | |
708 | arguments, call pedwarn_c11 and set no_named_args_stdarg_p. | |
709 | * c-tree.h (struct c_arg_info): Add field no_named_args_stdarg_p. | |
710 | * c-typeck.cc (composite_type): Handle | |
711 | TYPE_NO_NAMED_ARGS_STDARG_P. | |
712 | (function_types_compatible_p): Compare | |
713 | TYPE_NO_NAMED_ARGS_STDARG_P. | |
714 | ||
715 | 2022-10-28 Jakub Jelinek <jakub@redhat.com> | |
716 | ||
717 | * c-parser.cc (c_parser_omp_all_clauses): Allow optional | |
718 | comma before the first clause. | |
719 | (c_parser_omp_allocate, c_parser_omp_atomic, c_parser_omp_depobj, | |
720 | c_parser_omp_flush, c_parser_omp_scan_loop_body, | |
721 | c_parser_omp_ordered, c_finish_omp_declare_variant, | |
722 | c_parser_omp_declare_target, c_parser_omp_declare_reduction, | |
723 | c_parser_omp_requires, c_parser_omp_error, | |
724 | c_parser_omp_assumption_clauses): Likewise. | |
725 | ||
726 | 2022-10-28 Joseph Myers <joseph@codesourcery.com> | |
727 | ||
728 | PR c/61469 | |
729 | * c-convert.cc (c_convert): Handle enums with underlying boolean | |
730 | type like bool. | |
731 | * c-decl.cc (shadow_tag_warned): Allow shadowing declarations for | |
732 | enums with enum type specifier, but give errors for storage class | |
733 | specifiers, qualifiers or alignment specifiers in non-definition | |
734 | declarations of such enums. | |
735 | (grokdeclarator): Give error for non-definition use of type | |
736 | specifier with an enum type specifier. | |
737 | (parser_xref_tag): Add argument has_enum_type_specifier. Pass it | |
738 | to lookup_tag and use it to set ENUM_FIXED_UNDERLYING_TYPE_P. | |
739 | (xref_tag): Update call to parser_xref_tag. | |
740 | (start_enum): Add argument fixed_underlying_type. Complete enum | |
741 | type with a fixed underlying type given in the definition. Give | |
742 | error for defining without a fixed underlying type in the | |
743 | definition if one was given in a prior declaration. Do not mark | |
744 | enums with fixed underlying type as packed for -fshort-enums. | |
745 | Store the enum type in the_enum. | |
746 | (finish_enum): Do not adjust types of values or check their range | |
747 | for an enum with a fixed underlying type. Set underlying type of | |
748 | enum and variants. | |
749 | (build_enumerator): Check enumeration constants for enum with | |
750 | fixed underlying type against that type and convert to that type. | |
751 | Increment in the underlying integer type, with handling for bool. | |
752 | (c_simulate_enum_decl): Update call to start_enum. | |
753 | (declspecs_add_type): Set specs->enum_type_specifier_ref_p. | |
754 | * c-objc-common.cc (c_get_alias_set): Use ENUM_UNDERLYING_TYPE | |
755 | rather than recomputing an underlying type based on size. | |
756 | * c-parser.cc (c_parser_declspecs) | |
757 | (c_parser_struct_or_union_specifier, c_parser_typeof_specifier): | |
758 | Set has_enum_type_specifier for type specifiers. | |
759 | (c_parser_enum_specifier): Handle enum type specifiers. | |
760 | (c_parser_struct_or_union_specifier): Update call to | |
761 | parser_xref_tag. | |
762 | (c_parser_omp_atomic): Check for boolean increment or decrement | |
763 | using C_BOOLEAN_TYPE_P. | |
764 | * c-tree.h (C_BOOLEAN_TYPE_P): New. | |
765 | (struct c_typespec): Add has_enum_type_specifier. | |
766 | (struct c_declspecs): Add enum_type_specifier_ref_p. | |
767 | (struct c_enum_contents): Add enum_type. | |
768 | (start_enum, parser_xref_tag): Update prototypes. | |
769 | * c-typeck.cc (composite_type): Allow for enumerated types | |
770 | compatible with bool. | |
771 | (common_type, comptypes_internal, perform_integral_promotions): | |
772 | Use ENUM_UNDERLYING_TYPE. | |
773 | (parser_build_binary_op, build_unary_op, convert_for_assignment) | |
774 | (c_finish_return, c_start_switch, build_binary_op): Check for | |
775 | boolean types using C_BOOLEAN_TYPE_P. | |
776 | ||
4e939ae1 GA |
777 | 2022-10-24 Jakub Jelinek <jakub@redhat.com> |
778 | ||
779 | PR c++/107358 | |
780 | * c-typeck.cc (build_binary_op): Pass operands before excess precision | |
781 | promotions to scalar_to_vector call. | |
782 | ||
783 | 2022-10-24 Arsen Arsenović <arsen@aarsen.me> | |
784 | ||
785 | * c-decl.cc (finish_function): Ignore hosted when deciding | |
786 | whether to implicitly return zero, but check noreturn. | |
787 | * c-objc-common.cc (c_missing_noreturn_ok_p): Loosen the | |
788 | requirements to just MAIN_NAME_P when hosted, or `int main' | |
789 | otherwise. | |
790 | ||
47a6ae56 GA |
791 | 2022-10-20 Richard Biener <rguenther@suse.de> |
792 | ||
793 | PR c/107305 | |
794 | PR c/107306 | |
795 | * gimple-parser.cc (c_parser_parse_gimple_body): Verify | |
796 | the parsed IL and zap the body on error. | |
797 | ||
21de009f GA |
798 | 2022-10-18 Joseph Myers <joseph@codesourcery.com> |
799 | ||
800 | PR c/107164 | |
801 | * c-decl.cc (shadow_tag_warned): If pedantic, diagnose "enum tag;" | |
802 | with previous declaration visible. | |
803 | ||
804 | 2022-10-18 Joseph Myers <joseph@codesourcery.com> | |
805 | ||
806 | PR c/36113 | |
807 | * c-decl.cc (finish_enum): If any enumerators do not fit in int, | |
808 | convert all to the type of the enumeration. pedwarn if no integer | |
809 | type fits all enumerators and default to | |
810 | widest_integer_literal_type_node in that case. Otherwise pedwarn | |
811 | for type wider than intmax_t. | |
812 | (build_enumerator): pedwarn for enumerators outside the range of | |
813 | uintmax_t or intmax_t, and otherwise use pedwarn_c11 for | |
814 | enumerators outside the range of int. On overflow, attempt to | |
815 | find a wider type that can hold the value of the next enumerator. | |
816 | Do not convert value to type determined with | |
817 | c_common_type_for_size. | |
818 | ||
baeec7cc GA |
819 | 2022-10-14 Jakub Jelinek <jakub@redhat.com> |
820 | ||
821 | * c-typeck.cc (convert_arguments): Don't promote __bf16 to | |
822 | double. | |
823 | ||
824 | 2022-10-14 Joseph Myers <joseph@codesourcery.com> | |
825 | ||
826 | * c-decl.cc (build_compound_literal): Add parameter scspecs. | |
827 | Handle storage class specifiers. | |
828 | * c-parser.cc (c_token_starts_compound_literal) | |
829 | (c_parser_compound_literal_scspecs): New. | |
830 | (c_parser_postfix_expression_after_paren_type): Add parameter | |
831 | scspecs. Call pedwarn_c11 for use of storage class specifiers. | |
832 | Update call to build_compound_literal. | |
833 | (c_parser_cast_expression, c_parser_sizeof_expression) | |
834 | (c_parser_alignof_expression): Handle storage class specifiers for | |
835 | compound literals. Update calls to | |
836 | c_parser_postfix_expression_after_paren_type. | |
837 | (c_parser_postfix_expression): Update syntax comment. | |
838 | * c-tree.h (build_compound_literal): Update prototype. | |
839 | * c-typeck.cc (c_mark_addressable): Diagnose taking address of | |
840 | register compound literal. | |
841 | ||
9ff6c33e GA |
842 | 2022-10-07 Qing Zhao <qing.zhao@oracle.com> |
843 | ||
844 | * c-decl.cc (flexible_array_member_type_p): New function. | |
845 | (one_element_array_type_p): Likewise. | |
846 | (zero_length_array_type_p): Likewise. | |
847 | (add_flexible_array_elts_to_size): Call new utility | |
848 | routine flexible_array_member_type_p. | |
849 | (is_flexible_array_member_p): New function. | |
850 | (finish_struct): Set the new DECL_NOT_FLEXARRAY flag. | |
851 | ||
629d04d3 GA |
852 | 2022-10-06 Joseph Myers <joseph@codesourcery.com> |
853 | ||
854 | * c-parser.cc (c_parse_init): Add D_EXT11 to mask if flag_no_asm | |
855 | and not C2x. | |
856 | (c_keyword_starts_typename, c_token_starts_declspecs) | |
857 | (c_parser_declspecs, c_parser_objc_selector): Handle | |
858 | RID_TYPEOF_UNQUAL. | |
859 | (c_parser_typeof_specifier): Handle RID_TYPEOF_UNQUAL. | |
860 | Distinguish typeof for C2x from __typeof__ for all standard | |
861 | versions and typeof before C2x. | |
862 | * c-typeck.cc (build_function_call_vec): Use unqualified version | |
863 | of non-void return type. | |
864 | (build_unary_op): Use unqualified type for increment and | |
865 | decrement. | |
866 | ||
867 | 2022-10-06 Jakub Jelinek <jakub@redhat.com> | |
868 | ||
869 | * c-parser.cc (c_parser_omp_assumption_clauses): Emit IFN_ASSUME | |
870 | call for holds clause on assume construct. | |
871 | ||
872 | 2022-10-06 Jakub Jelinek <jakub@redhat.com> | |
873 | ||
874 | PR c++/106654 | |
875 | * c-parser.cc (handle_assume_attribute): New function. | |
876 | (c_parser_declaration_or_fndef): Handle assume attribute. | |
877 | (c_parser_attribute_arguments): Add assume_attr argument, | |
878 | if true, parse first argument as conditional expression. | |
879 | (c_parser_gnu_attribute, c_parser_std_attribute): Adjust | |
880 | c_parser_attribute_arguments callers. | |
881 | (c_parser_statement_after_labels) <case RID_ATTRIBUTE>: Handle | |
882 | assume attribute. | |
883 | ||
85872a69 GA |
884 | 2022-10-04 Jakub Jelinek <jakub@redhat.com> |
885 | ||
886 | * c-lang.h (struct c_omp_declare_target_attr): New type. | |
887 | (current_omp_declare_target_attribute): Change type from | |
888 | int to vec<c_omp_declare_target_attr, va_gc> *. | |
889 | * c-parser.cc (c_parser_translation_unit): Adjust for that change. | |
890 | If last pushed directive was begin declare target, use different | |
891 | wording and simplify format strings for easier translations. | |
892 | (c_parser_omp_clause_device_type): Uncomment | |
893 | check_no_duplicate_clause call. | |
894 | (c_parser_omp_declare_target): Adjust for the | |
895 | current_omp_declare_target_attribute type change, push { -1 }. | |
896 | Use error_at rather than warning_at for declare target with | |
897 | only device_type clauses. | |
898 | (OMP_BEGIN_DECLARE_TARGET_CLAUSE_MASK): Define. | |
899 | (c_parser_omp_begin): Add begin declare target support. | |
900 | (c_parser_omp_end): Adjust for the | |
901 | current_omp_declare_target_attribute type change, adjust | |
902 | diagnostics wording and simplify format strings for easier | |
903 | translations. | |
904 | * c-decl.cc (current_omp_declare_target_attribute): Change type from | |
905 | int to vec<c_omp_declare_target_attr, va_gc> *. | |
906 | (c_decl_attributes): Adjust for the | |
907 | current_omp_declare_target_attribute type change. If device_type | |
908 | was present on begin declare target, add "omp declare target host" | |
909 | and/or "omp declare target nohost" attributes. | |
910 | ||
bbdcdf5c GA |
911 | 2022-09-29 Joseph Myers <joseph@codesourcery.com> |
912 | ||
913 | * c-decl.cc (handle_std_noreturn_attribute): New function. | |
914 | (std_attribute_table): Add _Noreturn and noreturn. | |
915 | ||
1f16a020 GA |
916 | 2022-09-27 Jakub Jelinek <jakub@redhat.com> |
917 | ||
918 | * c-lang.h (current_omp_begin_assumes): Declare. | |
919 | * c-parser.cc: Include bitmap.h. | |
920 | (c_parser_omp_end_declare_target): Rename to ... | |
921 | (c_parser_omp_end): ... this. Handle also end assumes. | |
922 | (c_parser_omp_begin, c_parser_omp_assumption_clauses, | |
923 | c_parser_omp_assumes, c_parser_omp_assume): New functions. | |
924 | (c_parser_translation_unit): Also diagnose #pragma omp begin assumes | |
925 | without corresponding #pragma omp end assumes. | |
926 | (c_parser_pragma): Use %s in may only be used at file scope | |
927 | diagnostics to decrease number of translatable messages. Handle | |
928 | PRAGMA_OMP_BEGIN and PRAGMA_OMP_ASSUMES. Handle PRAGMA_OMP_END | |
929 | rather than PRAGMA_OMP_END_DECLARE_TARGET and call c_parser_omp_end | |
930 | for it rather than c_parser_omp_end_declare_target. | |
931 | (c_parser_omp_construct): Handle PRAGMA_OMP_ASSUME. | |
932 | * c-decl.cc (current_omp_begin_assumes): Define. | |
933 | ||
28a61ecd GA |
934 | 2022-09-24 Jakub Jelinek <jakub@redhat.com> |
935 | ||
936 | PR c/106981 | |
937 | * c-typeck.cc (c_tree_equal): Only strip NON_LVALUE_EXPRs at the | |
938 | start. For CONSTANT_CLASS_P or CASE_CONVERT: return false if t1 and | |
939 | t2 have different types. | |
940 | ||
279c6715 GA |
941 | 2022-09-22 David Malcolm <dmalcolm@redhat.com> |
942 | ||
943 | PR c/106830 | |
944 | * c-parser.cc (c_parser_initelt): Initialize m_decimal. | |
945 | (c_parser_cast_expression): Likewise. | |
946 | (c_parser_alignof_expression): Likewise. | |
947 | (c_parser_postfix_expression_after_paren_type): Likewise. | |
948 | (c_parser_postfix_expression_after_primary): Likewise. | |
949 | (c_parser_expression): Likewise. | |
950 | (c_parser_omp_variable_list): Likewise. | |
951 | (c_parser_transaction_expression): Likewise. | |
952 | * c-tree.h (c_expr::set_error): Likewise. | |
953 | * c-typeck.cc (c_expr_sizeof_expr): Likewise. | |
954 | (parser_build_unary_op): Likewise. | |
955 | (parser_build_binary_op): Likewise. | |
956 | (digest_init): Likewise. | |
957 | (pop_init_level): Likewise. | |
958 | * gimple-parser.cc (c_parser_gimple_call_internal): Likewise. | |
959 | ||
43be56c4 GA |
960 | 2022-09-19 Marek Polacek <polacek@redhat.com> |
961 | ||
962 | PR c/106947 | |
963 | * c-typeck.cc (maybe_warn_for_null_address): Don't emit stray | |
964 | notes. | |
965 | ||
d0fc05e8 GA |
966 | 2022-09-15 Richard Biener <rguenther@suse.de> |
967 | ||
968 | * c-decl.cc (build_void_list_node): Remove. | |
969 | ||
ff822367 GA |
970 | 2022-09-14 Julian Brown <julian@codesourcery.com> |
971 | ||
972 | * c-typeck.cc (c_finish_omp_clauses): Remove whole mapping node group | |
973 | on error. | |
974 | ||
fe2a8ce9 GA |
975 | 2022-09-07 Joseph Myers <joseph@codesourcery.com> |
976 | ||
977 | * c-parser.cc (c_parser_static_assert_declaration_no_semi) | |
978 | (c_parser_alignas_specifier, c_parser_alignof_expression): Allow | |
979 | for C2x spellings of keywords. | |
980 | (c_parser_postfix_expression): Handle RID_TRUE and RID_FALSE. | |
981 | ||
25aeb922 GA |
982 | 2022-09-06 Jakub Jelinek <jakub@redhat.com> |
983 | ||
984 | * c-parser.cc (c_parser_omp_clause_doacross_sink): Don't verify val | |
985 | in omp_cur_iteration - 1 has integer_type_node type. | |
986 | ||
83f2f228 GA |
987 | 2022-09-03 Jakub Jelinek <jakub@redhat.com> |
988 | ||
989 | * c-parser.cc (c_parser_omp_clause_name): Handle doacross. | |
990 | (c_parser_omp_clause_depend_sink): Renamed to ... | |
991 | (c_parser_omp_clause_doacross_sink): ... this. Add depend_p argument. | |
992 | Handle parsing of doacross(sink:omp_cur_iteration-1). Use | |
993 | OMP_CLAUSE_DOACROSS_SINK_NEGATIVE instead of | |
994 | OMP_CLAUSE_DEPEND_SINK_NEGATIVE, build OMP_CLAUSE_DOACROSS instead | |
995 | of OMP_CLAUSE_DEPEND and set OMP_CLAUSE_DOACROSS_DEPEND flag on it. | |
996 | (c_parser_omp_clause_depend): Use OMP_CLAUSE_DOACROSS_SINK and | |
997 | OMP_CLAUSE_DOACROSS_SOURCE instead of OMP_CLAUSE_DEPEND_SINK and | |
998 | OMP_CLAUSE_DEPEND_SOURCE, build OMP_CLAUSE_DOACROSS for depend(source) | |
999 | and set OMP_CLAUSE_DOACROSS_DEPEND on it. | |
1000 | (c_parser_omp_clause_doacross): New function. | |
1001 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_DOACROSS. | |
1002 | (c_parser_omp_depobj): Use OMP_CLAUSE_DEPEND_INVALID instead of | |
1003 | OMP_CLAUSE_DEPEND_SOURCE. | |
1004 | (c_parser_omp_for_loop): Don't diagnose here linear clause together | |
1005 | with ordered with argument. | |
1006 | (c_parser_omp_simd): Don't diagnose ordered clause with argument on | |
1007 | for simd. | |
1008 | (OMP_ORDERED_DEPEND_CLAUSE_MASK): Add PRAGMA_OMP_CLAUSE_DOACROSS. | |
1009 | (c_parser_omp_ordered): Handle also doacross and adjust for it | |
1010 | diagnostic wording. | |
1011 | * c-typeck.cc (c_finish_omp_clauses): Handle OMP_CLAUSE_DOACROSS. | |
1012 | Don't handle OMP_CLAUSE_DEPEND_SOURCE and OMP_CLAUSE_DEPEND_SINK. | |
1013 | ||
c64b0947 GA |
1014 | 2022-09-02 David Malcolm <dmalcolm@redhat.com> |
1015 | ||
1016 | PR c/90885 | |
1017 | * c-parser.cc (c_parser_string_literal): Clear ret.m_decimal. | |
1018 | (c_parser_expr_no_commas): Likewise. | |
1019 | (c_parser_conditional_expression): Likewise. | |
1020 | (c_parser_binary_expression): Clear m_decimal when popping the | |
1021 | stack. | |
1022 | (c_parser_unary_expression): Clear ret.m_decimal. | |
1023 | (c_parser_has_attribute_expression): Likewise for result. | |
1024 | (c_parser_predefined_identifier): Likewise for expr. | |
1025 | (c_parser_postfix_expression): Likewise for expr. | |
1026 | Set expr.m_decimal when handling a CPP_NUMBER that was a decimal | |
1027 | token. | |
1028 | * c-tree.h (c_expr::m_decimal): New bitfield. | |
1029 | * c-typeck.cc (parser_build_binary_op): Clear result.m_decimal. | |
1030 | (parser_build_binary_op): Call check_for_xor_used_as_pow. | |
1031 | ||
bb0a1556 GA |
1032 | 2022-09-01 Joseph Myers <joseph@codesourcery.com> |
1033 | ||
1034 | * c-decl.cc (grokparms): Handle () in a function declaration the | |
1035 | same as (void) for C2X. | |
1036 | ||
542c60c4 GA |
1037 | 2022-08-31 Joseph Myers <joseph@codesourcery.com> |
1038 | ||
1039 | * c-parser.cc (c_parser_label): Pass attributes to do_case. | |
1040 | * c-typeck.cc (do_case): Add argument ATTRS. Pass it to | |
1041 | c_add_case_label. | |
1042 | ||
16f542d6 GA |
1043 | 2022-08-26 Jakub Jelinek <jakub@redhat.com> |
1044 | ||
1045 | * c-typeck.cc (convert_arguments): Handle BUILT_IN_ISSIGNALING. | |
1046 | ||
5d4389dc GA |
1047 | 2022-08-25 Marek Polacek <polacek@redhat.com> |
1048 | ||
1049 | * c-convert.cc (c_convert) <case POINTER_TYPE>: Handle NULLPTR_TYPE. | |
1050 | Give a better diagnostic when converting to nullptr_t. | |
1051 | * c-decl.cc (c_init_decl_processing): Perform C-specific nullptr | |
1052 | initialization. | |
1053 | * c-parser.cc (c_parse_init): Maybe OR D_C2X into mask. | |
1054 | (c_parser_postfix_expression): Handle RID_NULLPTR. | |
1055 | * c-typeck.cc (null_pointer_constant_p): Return true when expr is | |
1056 | nullptr_node. | |
1057 | (build_unary_op) <case TRUTH_NOT_EXPR>: Handle NULLPTR_TYPE. | |
1058 | (build_conditional_expr): Handle the case when the second/third operand | |
1059 | is NULLPTR_TYPE and third/second operand is POINTER_TYPE. | |
1060 | (convert_for_assignment): Handle converting an expression of type | |
1061 | nullptr_t to pointer/bool. | |
1062 | (build_binary_op) <case TRUTH_XOR_EXPR>: Handle NULLPTR_TYPE. | |
1063 | <case EQ_EXPR>: Handle comparing operands of type nullptr_t. | |
1064 | ||
1065 | 2022-08-25 Joseph Myers <joseph@codesourcery.com> | |
1066 | ||
1067 | * c-decl.cc (start_decl): Do not diagnose initialization of | |
1068 | variable-sized objects here. | |
1069 | * c-parser.cc (c_parser_braced_init): Add argument DECL. All | |
1070 | callers changed. | |
1071 | (c_parser_initializer): Diagnose initialization of variable-sized | |
1072 | objects other than with braced initializer. | |
1073 | (c_parser_braced_init): Use pedwarn_c11 for empty initializer | |
1074 | braces and update diagnostic text. Diagnose initialization of | |
1075 | variable-sized objects with nonempty braces. | |
1076 | * c-typeck.cc (digest_init): Update diagnostic for initialization | |
1077 | of variable-sized objects. | |
1078 | (really_start_incremental_init, set_designator) | |
1079 | (process_init_element): Update comments. | |
1080 | (pop_init_level): Allow scalar empty initializers. | |
1081 | ||
0342f034 GA |
1082 | 2022-08-17 Tobias Burnus <tobias@codesourcery.com> |
1083 | Chung-Lin Tang <cltang@codesourcery.com> | |
1084 | ||
1085 | PR c++/104493 | |
1086 | * c-decl.cc (c_decl_attributes, finish_decl): Call omp_mappable_type | |
1087 | instead of removed langhook. | |
1088 | * c-typeck.cc (c_finish_omp_clauses): Likewise. | |
1089 | ||
5cd525f0 GA |
1090 | 2022-08-11 Marek Polacek <polacek@redhat.com> |
1091 | ||
1092 | PR middle-end/102633 | |
1093 | * c-parser.cc (c_parser_initializer): Add new tree parameter. Use it. | |
1094 | Call suppress_warning. | |
1095 | (c_parser_declaration_or_fndef): Pass d down to c_parser_initializer. | |
1096 | (c_parser_omp_declare_reduction): Pass omp_priv down to | |
1097 | c_parser_initializer. | |
1098 | ||
5f17badb GA |
1099 | 2022-08-08 Tom Honermann <tom@honermann.net> |
1100 | ||
1101 | * c-parser.cc (c_parser_string_literal): Use char8_t as the type | |
1102 | of CPP_UTF8STRING when char8_t support is enabled. | |
1103 | * c-typeck.cc (digest_init): Allow initialization of an array | |
1104 | of character type by a string literal with type array of | |
1105 | char8_t. | |
1106 | ||
32510382 GA |
1107 | 2022-08-01 David Malcolm <dmalcolm@redhat.com> |
1108 | ||
1109 | * c-typeck.cc (build_c_cast): Quote names of address spaces in | |
1110 | diagnostics. | |
1111 | (convert_for_assignment): Add a note to address space mismatch | |
1112 | diagnostics, specifying the expected and actual types. | |
1113 | ||
b53ebbc5 GA |
1114 | 2022-07-10 Lewis Hyatt <lhyatt@gmail.com> |
1115 | ||
1116 | PR preprocessor/97498 | |
1117 | * c-parser.cc (c_parser_pragma): Set input_location to the | |
1118 | location of the pragma, rather than the start of the line. | |
1119 | ||
8467574d GA |
1120 | 2022-07-04 Tobias Burnus <tobias@codesourcery.com> |
1121 | Chung-Lin Tang <cltang@codesourcery.com> | |
1122 | Thomas Schwinge <thomas@codesourcery.com> | |
1123 | ||
1124 | * c-parser.cc (c_parser_omp_target_data, c_parser_omp_target_update, | |
1125 | c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): Set | |
1126 | OMP_REQUIRES_TARGET_USED. | |
1127 | (c_parser_omp_requires): Remove sorry. | |
1128 | ||
ed974488 GA |
1129 | 2022-07-01 Tobias Burnus <tobias@codesourcery.com> |
1130 | ||
1131 | * c-parser.cc (c_parser_omp_target_enter_data, | |
1132 | c_parser_omp_target_exit_data): Accept tofrom | |
1133 | map-type modifier but use 'to' / 'from' internally. | |
1134 | ||
bc7e9f76 GA |
1135 | 2022-06-16 David Malcolm <dmalcolm@redhat.com> |
1136 | ||
1137 | * c-decl.cc (implicitly_declare): Add auto_diagnostic_group to | |
1138 | group the warning with any note. | |
1139 | (warn_about_goto): Likewise to group error or warning with note. | |
1140 | Bail out if the warning wasn't emitted, to avoid emitting orphan | |
1141 | notes. | |
1142 | (lookup_label_for_goto): Add auto_diagnostic_group to | |
1143 | group the error with the note. | |
1144 | (check_earlier_gotos): Likewise. | |
1145 | (c_check_switch_jump_warnings): Likewise for any error/warning. | |
1146 | Conditionalize emission of the notes. | |
1147 | (diagnose_uninitialized_cst_member): Likewise for warning, | |
1148 | conditionalizing emission of the note. | |
1149 | (grokdeclarator): Add auto_diagnostic_group to group the "array | |
1150 | type has incomplete element type" error with any note. | |
1151 | (parser_xref_tag): Add auto_diagnostic_group to group warnings | |
1152 | with their notes. Conditionalize emission of notes. | |
1153 | (start_struct): Add auto_diagnostic_group to group the | |
1154 | "redefinition of" errors with any note. | |
1155 | (start_enum): Likewise for "redeclaration of %<enum %E%>" error. | |
1156 | (check_for_loop_decls): Likewise for pre-C99 error. | |
1157 | ||
445ba599 GA |
1158 | 2022-06-07 Jakub Jelinek <jakub@redhat.com> |
1159 | ||
1160 | * c-parser.cc (c_parser_omp_clause_linear): Parse OpenMP 5.2 | |
1161 | style linear clause modifiers. Set | |
1162 | OMP_CLAUSE_LINEAR_OLD_LINEAR_MODIFIER flag on the clauses when | |
1163 | old style modifiers are used. | |
1164 | * c-typeck.cc (c_finish_omp_clauses): Only reject linear clause | |
1165 | with val modifier on simd or for if the old style modifiers are | |
1166 | used. | |
1167 | ||
b168441c GA |
1168 | 2022-06-02 David Malcolm <dmalcolm@redhat.com> |
1169 | ||
1170 | * c-lang.cc (LANG_HOOKS_GET_SARIF_SOURCE_LANGUAGE): Redefine. | |
1171 | (c_get_sarif_source_language): New. | |
1172 | * c-tree.h (c_get_sarif_source_language): New decl. | |
1173 | ||
820ead45 GA |
1174 | 2022-05-31 Jason Merrill <jason@redhat.com> |
1175 | ||
1176 | * Make-lang.in (c.tags): Look at *.cc. | |
1177 | ||
1178 | 2022-05-31 Jakub Jelinek <jakub@redhat.com> | |
1179 | ||
1180 | * c-parser.cc (OMP_SCOPE_CLAUSE_MASK): Add firstprivate and allocate | |
1181 | clauses. | |
1182 | ||
37b3b5da GA |
1183 | 2022-05-28 Jakub Jelinek <jakub@redhat.com> |
1184 | ||
1185 | * c-parser.cc (c_parser_omp_declare_target): If OMP_CLAUSE_LINK was | |
1186 | seen first, use "%<to%>" or "%<enter%>" depending on | |
1187 | OMP_CLAUSE_ENTER_TO of the current clause, otherwise use | |
1188 | "%<to%> or %<enter%>" wording. | |
1189 | ||
d9176e64 GA |
1190 | 2022-05-27 Jakub Jelinek <jakub@redhat.com> |
1191 | ||
1192 | * c-parser.cc (c_parser_omp_clause_name): Parse enter clause. | |
1193 | (c_parser_omp_all_clauses): For to clause on declare target, use | |
1194 | OMP_CLAUSE_ENTER clause with OMP_CLAUSE_ENTER_TO instead of | |
1195 | OMP_CLAUSE_TO_DECLARE clause. Handle PRAGMA_OMP_CLAUSE_ENTER. | |
1196 | (OMP_DECLARE_TARGET_CLAUSE_MASK): Add enter clause. | |
1197 | (c_parser_omp_declare_target): Use OMP_CLAUSE_ENTER instead of | |
1198 | OMP_CLAUSE_TO_DECLARE. | |
1199 | * c-typeck.cc (c_finish_omp_clauses): Handle OMP_CLAUSE_ENTER instead | |
1200 | of OMP_CLAUSE_TO_DECLARE, to OMP_CLAUSE_ENTER_TO use "to" as clause | |
1201 | name in diagnostics instead of | |
1202 | omp_clause_code_name[OMP_CLAUSE_CODE (c)]. | |
1203 | ||
3dff965c GA |
1204 | 2022-05-25 Jakub Jelinek <jakub@redhat.com> |
1205 | ||
1206 | PR c/91134 | |
1207 | * c-tree.h (build_component_ref): Add ARROW_LOC location_t argument. | |
1208 | * c-typeck.cc (build_component_ref): Likewise. If DATUM is | |
1209 | INDIRECT_REF and ARROW_LOC isn't UNKNOWN_LOCATION, print a different | |
1210 | diagnostic and fixit hint if DATUM has pointer type. | |
1211 | * c-parser.cc (c_parser_postfix_expression, | |
1212 | c_parser_omp_variable_list): Adjust build_component_ref callers. | |
1213 | * gimple-parser.cc (c_parser_gimple_postfix_expression_after_primary): | |
1214 | Likewise. | |
1215 | ||
768f49a2 GA |
1216 | 2022-05-24 Jakub Jelinek <jakub@redhat.com> |
1217 | ||
1218 | PR c/105378 | |
1219 | * c-parser.cc (OMP_TASKWAIT_CLAUSE_MASK): Add nowait clause. | |
1220 | ||
1cda629f GA |
1221 | 2022-05-18 Marek Polacek <polacek@redhat.com> |
1222 | ||
1223 | PR c/105131 | |
1224 | * c-decl.cc (diagnose_mismatched_decls): Warn about enum/integer type | |
1225 | mismatches. | |
1226 | * c-tree.h (comptypes_check_enum_int): Declare. | |
1227 | * c-typeck.cc (comptypes): No longer static. | |
1228 | ||
3d9439b1 GA |
1229 | 2022-05-17 Marek Polacek <polacek@redhat.com> |
1230 | ||
1231 | * c-decl.cc (finish_enum): Store the CONST_DECL into TREE_VALUE, not | |
1232 | its value. | |
1233 | ||
1234 | 2022-05-17 Jakub Jelinek <jakub@redhat.com> | |
1235 | ||
1236 | * c-parser.cc (c_parser_omp_clause_depend): Parse | |
1237 | inoutset depend-kind. | |
1238 | (c_parser_omp_depobj): Likewise. | |
1239 | ||
702bd11f GA |
1240 | 2022-05-16 Martin Liska <mliska@suse.cz> |
1241 | ||
1242 | * c-decl.cc (match_builtin_function_types): Use ARRAY_SIZE. | |
1243 | ||
49ace834 GA |
1244 | 2022-05-12 Jakub Jelinek <jakub@redhat.com> |
1245 | ||
1246 | * c-parser.cc (c_parse_init): Register omp_all_memory as keyword | |
1247 | if flag_openmp. | |
1248 | (c_parser_postfix_expression): Diagnose uses of omp_all_memory | |
1249 | in postfix expressions. | |
1250 | (c_parser_omp_variable_list): Handle omp_all_memory in depend | |
1251 | clause. | |
1252 | * c-typeck.cc (c_finish_omp_clauses): Handle omp_all_memory | |
1253 | keyword in depend clause as null_pointer_node, diagnose invalid | |
1254 | uses. | |
1255 | ||
bd022ff9 GA |
1256 | 2022-05-09 Martin Liska <mliska@suse.cz> |
1257 | ||
1258 | * c-parser.cc (c_parser_conditional_expression): Use {,UN}LIKELY | |
1259 | macros. | |
1260 | (c_parser_binary_expression): Likewise. | |
1261 | ||
a1947c92 GA |
1262 | 2022-05-07 Marek Polacek <polacek@redhat.com> |
1263 | ||
1264 | PR c++/101833 | |
1265 | PR c++/47634 | |
1266 | * c-objc-common.cc (maybe_adjust_arg_pos_for_attribute): New. | |
1267 | ||
405eda0d GA |
1268 | 2022-04-08 Jakub Jelinek <jakub@redhat.com> |
1269 | ||
1270 | PR c/105149 | |
1271 | * c-typeck.cc (c_build_va_arg): Reject function types. | |
1272 | ||
a2287813 GA |
1273 | 2022-03-22 Marek Polacek <polacek@redhat.com> |
1274 | ||
1275 | PR c/82283 | |
1276 | PR c/84685 | |
1277 | * c-typeck.cc (struct initializer_stack): Add 'designated' member. | |
1278 | (start_init): Set it. | |
1279 | (finish_init): Restore constructor_designated. | |
1280 | (push_init_level): Set constructor_designated to the value of | |
1281 | constructor_designated in the upper constructor_stack. | |
1282 | ||
57eeedda GA |
1283 | 2022-03-12 Thomas Schwinge <thomas@codesourcery.com> |
1284 | ||
1285 | PR other/65095 | |
1286 | * c-typeck.cc (handle_omp_array_sections_1) | |
1287 | (c_oacc_check_attachments): Call 'user_omp_clause_code_name' | |
1288 | instead of 'c_omp_map_clause_name'. | |
1289 | ||
8cc4f9cd GA |
1290 | 2022-03-09 Joseph Myers <joseph@codesourcery.com> |
1291 | ||
1292 | * c-typeck.cc (function_types_compatible_p): Do not handle C2X | |
1293 | differently from earlier standards for unprototyped function type | |
1294 | compatibility. | |
1295 | ||
1296 | 2022-03-09 Jakub Jelinek <jakub@redhat.com> | |
1297 | ||
1298 | PR c/104711 | |
1299 | * c-fold.cc (c_fully_fold_internal): Don't emit | |
1300 | -Wshift-negative-value warning if TYPE_OVERFLOW_WRAPS. | |
1301 | * c-typeck.cc (build_binary_op): Likewise. | |
1302 | ||
e6533e2e GA |
1303 | 2022-03-07 Jakub Jelinek <jakub@redhat.com> |
1304 | ||
1305 | * c-parser.cc (c_parser_omp_clause_map): Add missing space in string | |
1306 | literal. | |
1307 | ||
4bf3bac1 GA |
1308 | 2022-02-23 Richard Biener <rguenther@suse.de> |
1309 | ||
1310 | * gimple-parser.cc (c_parser_parse_gimple_body): Diagnose | |
1311 | SSA names without definition. | |
1312 | (c_parser_gimple_declaration): Handle pointer typed SSA names. | |
1313 | ||
0bdb0498 GA |
1314 | 2022-02-17 Jakub Jelinek <jakub@redhat.com> |
1315 | ||
1316 | PR c/104532 | |
1317 | * c-parser.cc (c_parser_omp_variable_list): For CPP_DEREF, use | |
1318 | convert_lvalue_to_rvalue and build_indirect_ref instead of | |
1319 | build_simple_mem_ref. | |
1320 | ||
e8d68f0a GA |
1321 | 2022-02-11 Richard Biener <rguenther@suse.de> |
1322 | ||
1323 | * gimple-parser.cc (c_parser_gimple_statement): Properly parse | |
1324 | VEC_COND_EXPRs. | |
1325 | ||
a645583d GA |
1326 | 2022-02-10 Marcel Vollweiler <marcel@codesourcery.com> |
1327 | ||
1328 | * c-parser.cc (c_parser_omp_clause_name): Parse 'has_device_addr' | |
1329 | clause. | |
1330 | (c_parser_omp_variable_list): Handle array sections. | |
1331 | (c_parser_omp_clause_has_device_addr): Added. | |
1332 | (c_parser_omp_all_clauses): Added PRAGMA_OMP_CLAUSE_HAS_DEVICE_ADDR | |
1333 | case. | |
1334 | (c_parser_omp_target_exit_data): Added HAS_DEVICE_ADDR to | |
1335 | OMP_CLAUSE_MASK. | |
1336 | * c-typeck.cc (handle_omp_array_sections): Handle clause restrictions. | |
1337 | (c_finish_omp_clauses): Handle array sections. | |
1338 | ||
3adf509f GA |
1339 | 2022-02-09 Jakub Jelinek <jakub@redhat.com> |
1340 | ||
1341 | PR c/104427 | |
1342 | * c-parser.cc (c_parser_postfix_expression) | |
1343 | <case RID_BUILTIN_ASSOC_BARRIER>: Use parser_build_unary_op | |
1344 | instead of build1_loc to build PAREN_EXPR. | |
1345 | * c-typeck.cc (build_unary_op): Handle PAREN_EXPR. | |
1346 | * c-fold.cc (c_fully_fold_internal): Likewise. | |
1347 | ||
fc829782 GA |
1348 | 2022-01-17 Martin Liska <mliska@suse.cz> |
1349 | ||
1350 | * Make-lang.in: Rename .c names to .cc. | |
1351 | * c-convert.cc: Likewise. | |
1352 | * c-decl.cc (struct lang_identifier): Likewise. | |
1353 | (pop_scope): Likewise. | |
1354 | (finish_decl): Likewise. | |
1355 | * c-objc-common.h (GCC_C_OBJC_COMMON): Likewise. | |
1356 | * c-parser.cc (c_parser_skip_to_end_of_block_or_statement): Likewise. | |
1357 | * c-parser.h (GCC_C_PARSER_H): Likewise. | |
1358 | * c-tree.h (c_keyword_starts_typename): Likewise. | |
1359 | (finish_declspecs): Likewise. | |
1360 | (c_get_alias_set): Likewise. | |
1361 | (enum c_oracle_request): Likewise. | |
1362 | (tag_exists_p): Likewise. | |
1363 | (set_c_expr_source_range): Likewise. | |
1364 | * c-typeck.cc (c_common_type): Likewise. | |
1365 | (c_finish_omp_clauses): Likewise. | |
1366 | * config-lang.in: Likewise. | |
1367 | ||
1368 | 2022-01-17 Martin Liska <mliska@suse.cz> | |
1369 | ||
1370 | * c-aux-info.c: Moved to... | |
1371 | * c-aux-info.cc: ...here. | |
1372 | * c-convert.c: Moved to... | |
1373 | * c-convert.cc: ...here. | |
1374 | * c-decl.c: Moved to... | |
1375 | * c-decl.cc: ...here. | |
1376 | * c-errors.c: Moved to... | |
1377 | * c-errors.cc: ...here. | |
1378 | * c-fold.c: Moved to... | |
1379 | * c-fold.cc: ...here. | |
1380 | * c-lang.c: Moved to... | |
1381 | * c-lang.cc: ...here. | |
1382 | * c-objc-common.c: Moved to... | |
1383 | * c-objc-common.cc: ...here. | |
1384 | * c-parser.c: Moved to... | |
1385 | * c-parser.cc: ...here. | |
1386 | * c-typeck.c: Moved to... | |
1387 | * c-typeck.cc: ...here. | |
1388 | * gccspec.c: Moved to... | |
1389 | * gccspec.cc: ...here. | |
1390 | * gimple-parser.c: Moved to... | |
1391 | * gimple-parser.cc: ...here. | |
1392 | ||
1393 | 2022-01-17 Andrew Stubbs <ams@codesourcery.com> | |
1394 | ||
1395 | * c-parser.c (c_parser_omp_requires): Don't "sorry" dynamic_allocators. | |
1396 | ||
617db51d GA |
1397 | 2022-01-14 Chung-Lin Tang <cltang@codesourcery.com> |
1398 | ||
1399 | PR c++/103705 | |
1400 | * c-typeck.c (c_finish_omp_clauses): Also continue peeling off of | |
1401 | outer node for ARRAY_REFs. | |
1402 | ||
62eb5308 GA |
1403 | 2022-01-01 Jakub Jelinek <jakub@redhat.com> |
1404 | ||
1405 | PR objc/103639 | |
1406 | * c-typeck.c (c_finish_bc_stmt): For break inside of switch inside of | |
1407 | ObjC foreach, emit normal BREAK_STMT rather than goto to label. | |
1408 | ||
2554e2da GA |
1409 | 2021-12-17 Marek Polacek <polacek@redhat.com> |
1410 | ||
1411 | PR c/103649 | |
1412 | * c-decl.c (c_warn_unused_attributes): Don't warn for | |
1413 | attribute_ignored_p. | |
1414 | * c-parser.c (c_parser_std_attribute): Skip parsing of the attribute | |
1415 | arguments when the attribute is ignored. | |
1416 | ||
9c6586bc GA |
1417 | 2021-12-14 Jakub Jelinek <jakub@redhat.com> |
1418 | ||
1419 | PR c/103587 | |
1420 | * c-parser.c (c_parser_balanced_token_sequence): For CPP_PRAGMA, | |
1421 | consume the pragma and silently skip to the pragma eol. | |
1422 | ||
c8dcf64b GA |
1423 | 2021-12-12 Jonathan Wakely <jwakely@redhat.com> |
1424 | ||
1425 | * c-decl.c: Define INCLUDE_MEMORY instead of INCLUDE_UNIQUE_PTR. | |
1426 | * c-parser.c: Likewise. | |
1427 | ||
4b4839e3 GA |
1428 | 2021-12-09 Jakub Jelinek <jakub@redhat.com> |
1429 | ||
1430 | PR pch/71934 | |
1431 | * c-decl.c (resort_field_decl_cmp): Pass the same pointer twice | |
1432 | to resort_data.new_value. | |
1433 | ||
641ff219 GA |
1434 | 2021-12-08 Chung-Lin Tang <cltang@codesourcery.com> |
1435 | ||
1436 | * c-parser.c (struct omp_dim): New struct type for use inside | |
1437 | c_parser_omp_variable_list. | |
1438 | (c_parser_omp_variable_list): Allow multiple levels of array and | |
1439 | component accesses in array section base-pointer expression. | |
1440 | (c_parser_omp_clause_to): Set 'allow_deref' to true in call to | |
1441 | c_parser_omp_var_list_parens. | |
1442 | (c_parser_omp_clause_from): Likewise. | |
1443 | * c-typeck.c (handle_omp_array_sections_1): Extend allowed range | |
1444 | of base-pointer expressions involving INDIRECT/MEM/ARRAY_REF and | |
1445 | POINTER_PLUS_EXPR. | |
1446 | (c_finish_omp_clauses): Extend allowed ranged of expressions | |
1447 | involving INDIRECT/MEM/ARRAY_REF and POINTER_PLUS_EXPR. | |
1448 | ||
1449 | 2021-12-08 Chung-Lin Tang <cltang@codesourcery.com> | |
1450 | ||
1451 | PR middle-end/92120 | |
1452 | * c-parser.c (c_parser_omp_clause_map): Set 'allow_deref' argument in | |
1453 | call to c_parser_omp_variable_list to 'true'. | |
1454 | * c-typeck.c (handle_omp_array_sections_1): Add strip of MEM_REF in | |
1455 | array base handling. | |
1456 | (c_finish_omp_clauses): Handle 'A->member' case in map clauses. | |
1457 | ||
c177e806 GA |
1458 | 2021-11-30 Thomas Schwinge <thomas@codesourcery.com> |
1459 | ||
1460 | * c-typeck.c (c_finish_omp_clauses): Remove "gang reduction on an | |
1461 | orphan loop" checking. | |
1462 | ||
1463 | 2021-11-30 Cesar Philippidis <cesar@codesourcery.com> | |
1464 | Thomas Schwinge <thomas@codesourcery.com> | |
1465 | ||
1466 | * c-typeck.c (c_finish_omp_clauses): Emit an error on orphan | |
1467 | OpenACC gang reductions. | |
1468 | ||
1469 | 2021-11-30 Richard Biener <rguenther@suse.de> | |
1470 | ||
1471 | * gimple-parser.c (c_parser_gimple_postfix_expression): | |
1472 | avoid unreachable code after break. | |
1473 | ||
87cd82c8 GA |
1474 | 2021-11-29 Eric Gallager <egallager@gcc.gnu.org> |
1475 | ||
1476 | PR other/103021 | |
1477 | * Make-lang.in: Use ETAGS variable in TAGS target. | |
1478 | ||
1479 | 2021-11-29 Richard Biener <rguenther@suse.de> | |
1480 | ||
1481 | * c-typeck.c (c_tree_equal): Remove unreachable return. | |
1482 | * c-parser.c (get_matching_symbol): Likewise. | |
1483 | ||
e1d43592 GA |
1484 | 2021-11-23 Jakub Jelinek <jakub@redhat.com> |
1485 | ||
1486 | * c-typeck.c (c_clone_omp_udr): Don't initialize | |
1487 | id.transform_lang_insert_block. | |
1488 | ||
9c077398 GA |
1489 | 2021-11-19 Martin Sebor <msebor@redhat.com> |
1490 | ||
1491 | PR c++/33925 | |
1492 | PR c/102867 | |
1493 | * c-typeck.c (maybe_warn_for_null_address): Suppress warnings for | |
1494 | code resulting from macro expansion. | |
1495 | ||
1496 | 2021-11-19 Martin Liska <mliska@suse.cz> | |
1497 | ||
1498 | Revert: | |
1499 | 2021-11-19 Martin Liska <mliska@suse.cz> | |
1500 | ||
1501 | * c-parser.c (add_debug_begin_stmt): Use option directly. | |
1502 | ||
483092d3 GA |
1503 | 2021-11-18 Matthias Kretz <m.kretz@gsi.de> |
1504 | ||
1505 | * c-decl.c (names_builtin_p): Handle RID_BUILTIN_ASSOC_BARRIER. | |
1506 | * c-parser.c (c_parser_postfix_expression): Likewise. | |
1507 | ||
1508 | 2021-11-18 Martin Liska <mliska@suse.cz> | |
1509 | ||
1510 | * c-parser.c (add_debug_begin_stmt): Use option directly. | |
1511 | ||
280d2838 GA |
1512 | 2021-11-17 Martin Sebor <msebor@redhat.com> |
1513 | ||
1514 | PR c/101702 | |
1515 | * c-decl.c (get_parm_array_spec): Strip casts earlier and fold array | |
1516 | bounds before deciding if they're constant. | |
1517 | ||
e2b57363 GA |
1518 | 2021-11-15 Jakub Jelinek <jakub@redhat.com> |
1519 | ||
1520 | * c-parser.c (OMP_TARGET_CLAUSE_MASK): Add | |
1521 | PRAGMA_OMP_CLAUSE_THREAD_LIMIT. | |
1522 | ||
b39265d4 GA |
1523 | 2021-11-11 Jakub Jelinek <jakub@redhat.com> |
1524 | ||
1525 | * c-parser.c (c_parser_omp_clause_num_teams): Parse optional | |
1526 | lower-bound and store it into OMP_CLAUSE_NUM_TEAMS_LOWER_EXPR. | |
1527 | Use OMP_CLAUSE_NUM_TEAMS_UPPER_EXPR instead of | |
1528 | OMP_CLAUSE_NUM_TEAMS_EXPR. | |
1529 | (c_parser_omp_target): For OMP_CLAUSE_NUM_TEAMS evaluate before | |
1530 | combined target teams even lower-bound expression. | |
1531 | ||
1532 | 2021-11-11 Richard Biener <rguenther@suse.de> | |
1533 | ||
1534 | * gimple-parser.c: Shuffle bitmap.h include. | |
1535 | ||
18ae471f GA |
1536 | 2021-11-03 Joseph Myers <joseph@codesourcery.com> |
1537 | ||
1538 | PR c/103031 | |
1539 | * c-convert.c (c_convert): New function, based on convert. | |
1540 | (convert): Make into wrapper of c_convert. | |
1541 | (convert_init): New function. | |
1542 | * c-typeck.c (enum impl_conv): Add ic_init_const. | |
1543 | (convert_for_assignment): Handle ic_init_const like ic_init. Add | |
1544 | new argument to convert_and_check call. | |
1545 | (digest_init): Pass ic_init_const to convert_for_assignment for | |
1546 | initializers required to be constant. | |
1547 | ||
b4df2dd3 GA |
1548 | 2021-11-02 Richard Sandiford <richard.sandiford@arm.com> |
1549 | ||
1550 | * c-tree.h (c_simulate_record_decl): Declare. | |
1551 | * c-objc-common.h (LANG_HOOKS_SIMULATE_RECORD_DECL): Override. | |
1552 | * c-decl.c (c_simulate_record_decl): New function. | |
1553 | ||
c2bd5d8a GA |
1554 | 2021-10-22 Eric Gallager <egallager@gcc.gnu.org> |
1555 | ||
1556 | PR other/102663 | |
1557 | * Make-lang.in: Add dummy c.install-dvi target. | |
1558 | ||
93d183a5 GA |
1559 | 2021-10-15 Richard Biener <rguenther@suse.de> |
1560 | ||
1561 | PR c/102763 | |
1562 | * gimple-parser.c | |
1563 | (c_parser_gimple_postfix_expression_after_primary): Check | |
1564 | for a pointer do be dereferenced by ->. | |
1565 | ||
5d5885c9 GA |
1566 | 2021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com> |
1567 | ||
1568 | * c-parser.c (c_finish_omp_declare_variant): Change call from | |
1569 | c_omp_check_context_selector to omp_check_context_selector. Change | |
1570 | call from c_omp_mark_declare_variant to omp_mark_declare_variant. | |
1571 | ||
c9db17b8 GA |
1572 | 2021-10-09 Jakub Jelinek <jakub@redhat.com> |
1573 | ||
1574 | * c-parser.c (c_parser_omp_structured_block_sequence): New function. | |
1575 | (c_parser_omp_scan_loop_body): Use it. | |
1576 | (c_parser_omp_sections_scope): Likewise. | |
1577 | ||
50e20ee6 GA |
1578 | 2021-10-07 Richard Biener <rguenther@suse.de> |
1579 | ||
1580 | * c-typeck.c (lvalue_p): Also allow MEM_REF and TARGET_MEM_REF. | |
1581 | ||
bb6194e0 GA |
1582 | 2021-10-05 Richard Biener <rguenther@suse.de> |
1583 | ||
1584 | PR c/102605 | |
1585 | * gimple-parser.c (c_parser_gimple_postfix_expression): | |
1586 | Accept more address _Literals. | |
1587 | ||
da9c5f78 GA |
1588 | 2021-10-04 Marek Polacek <polacek@redhat.com> |
1589 | ||
1590 | PR c++/97573 | |
1591 | * c-typeck.c (parser_build_binary_op): Call do_warn_array_compare. | |
1592 | ||
9d116bcc GA |
1593 | 2021-10-01 Martin Sebor <msebor@redhat.com> |
1594 | ||
1595 | PR c/102103 | |
1596 | * c-typeck.c (maybe_warn_for_null_address): New function. | |
1597 | (build_binary_op): Call it. | |
1598 | ||
1599 | 2021-10-01 Jakub Jelinek <jakub@redhat.com> | |
1600 | Richard Biener <rguenther@suse.de> | |
1601 | ||
1602 | PR sanitizer/102515 | |
1603 | * c-typeck.c (build_binary_op): Call ubsan_instrument_division | |
1604 | for division even for SANITIZE_SI_OVERFLOW. | |
1605 | ||
1606 | 2021-10-01 Jakub Jelinek <jakub@redhat.com> | |
1607 | ||
1608 | * c-parser.c (c_parser_omp_clause_order): Set | |
1609 | OMP_CLAUSE_ORDER_REPRODUCIBLE for explicit reproducible: modifier. | |
1610 | ||
fd133479 GA |
1611 | 2021-09-28 Andrew Pinski <apinski@marvell.com> |
1612 | ||
1613 | PR c/32122 | |
1614 | * c-parser.c (c_parser_statement_after_labels): Pass | |
1615 | the c_expr instead of the tree to c_finish_goto_ptr. | |
1616 | * c-typeck.c (c_finish_goto_ptr): Change the second | |
1617 | argument type to c_expr. | |
1618 | * c-tree.h (c_finish_goto_ptr): Likewise. | |
1619 | Error out if the expression was not of a pointer type. | |
1620 | ||
e4777439 GA |
1621 | 2021-09-22 Jakub Jelinek <jakub@redhat.com> |
1622 | ||
1623 | * c-parser.c (c_parser_omp_clause_allocate): Parse allocate clause | |
1624 | modifiers. | |
1625 | ||
cf74e7b5 GA |
1626 | 2021-09-18 Jakub Jelinek <jakub@redhat.com> |
1627 | ||
1628 | * c-parser.c (c_parser_omp_clause_order): Parse unconstrained | |
1629 | and reproducible modifiers. | |
1630 | (OMP_DISTRIBUTE_CLAUSE_MASK): Add order clause. | |
1631 | ||
1632 | 2021-09-18 Jakub Jelinek <jakub@redhat.com> | |
1633 | ||
1634 | * c-parser.c (c_parser_omp_clause_default): Handle private and | |
1635 | firstprivate arguments, adjust diagnostics on unknown argument. | |
1636 | ||
0a4cb439 GA |
1637 | 2021-09-17 Jakub Jelinek <jakub@redhat.com> |
1638 | ||
1639 | * c-parser.c (c_parser_omp_atomic): Reject atomic swap if capture | |
1640 | is true. | |
1641 | ||
a26206ec GA |
1642 | 2021-09-10 Jakub Jelinek <jakub@redhat.com> |
1643 | ||
1644 | * c-parser.c (c_parser_conditional_expression): If omp_atomic_lhs and | |
1645 | cond.value is >, < or == with omp_atomic_lhs as one of the operands, | |
1646 | don't call build_conditional_expr, instead build a COND_EXPR directly. | |
1647 | (c_parser_binary_expression): Avoid calling parser_build_binary_op | |
1648 | if omp_atomic_lhs even in more cases for >, < or ==. | |
1649 | (c_parser_omp_atomic): Update function comment for OpenMP 5.1 atomics, | |
1650 | parse OpenMP 5.1 atomics and fail, compare and weak clauses, allow | |
1651 | acq_rel on atomic read/write and acq_rel/acquire clauses on update. | |
1652 | * c-typeck.c (build_binary_op): For flag_openmp only handle | |
1653 | MIN_EXPR/MAX_EXPR. | |
1654 | ||
b2748138 GA |
1655 | 2021-09-07 Marcel Vollweiler <marcel@codesourcery.com> |
1656 | ||
1657 | * c-parser.c (c_parser_omp_flush): Parse 'seq_cst' clause on 'flush' | |
1658 | directive. | |
1659 | ||
e11c6046 GA |
1660 | 2021-09-01 Iain Sandoe <iain@sandoe.co.uk> |
1661 | ||
1662 | * c-decl.c (enum deprecated_states): Add unavailable state. | |
1663 | (merge_decls): Copy unavailability. | |
1664 | (quals_from_declspecs): Handle unavailable case. | |
1665 | (start_decl): Amend the logic handling suppression of nested | |
1666 | deprecation states to include unavailability. | |
1667 | (smallest_type_quals_location): Amend comment. | |
1668 | (grokdeclarator): Handle the unavailable deprecation state. | |
1669 | (declspecs_add_type): Set TREE_UNAVAILABLE from the decl specs. | |
1670 | * c-tree.h (struct c_declspecs): Add unavailable_p. | |
1671 | * c-typeck.c (build_component_ref): Handle unavailability. | |
1672 | (build_external_ref): Likewise. | |
1673 | ||
1674 | 2021-09-01 Roger Sayle <roger@nextmovesoftware.com> | |
1675 | Joseph Myers <joseph@codesourcery.com> | |
1676 | ||
1677 | PR c/79412 | |
1678 | * c-decl.c (duplicate_decls): On significant mismatches, mark the | |
1679 | types of both (non-function) decls as error_mark_node, so that the | |
1680 | middle-end can see the code is malformed. | |
1681 | (free_attr_access_data): Don't process if the type has been set to | |
1682 | error_mark_node. | |
1683 | ||
6d51ee43 GA |
1684 | 2021-08-31 Marcel Vollweiler <marcel@codesourcery.com> |
1685 | ||
1686 | * c-parser.c (c_parser_omp_clause_device): Parse device-modifiers 'device_num' | |
1687 | and 'ancestor' in 'target device' clauses. | |
1688 | ||
38b19c5b GA |
1689 | 2021-08-23 Jakub Jelinek <jakub@redhat.com> |
1690 | ||
1691 | * c-parser.c (c_parser_omp_clause_num_tasks, | |
1692 | c_parser_omp_clause_grainsize): Parse the optional strict: modifier. | |
1693 | ||
5b2876f9 GA |
1694 | 2021-08-22 Martin Uecker <muecker@gwdg.de> |
1695 | ||
1696 | PR c/98397 | |
1697 | * c-typeck.c (comp_target_types): Change pedwarn to pedwarn_c11 | |
1698 | for pointers to arrays with qualifiers. | |
1699 | (build_conditional_expr): For C23 don't lose qualifiers for pointers | |
1700 | to arrays when the other pointer is a void pointer. Update warnings. | |
1701 | (convert_for_assignment): Update warnings for C2X when converting from | |
1702 | void* with qualifiers to a pointer to array with the same qualifiers. | |
1703 | ||
7c9e1645 GA |
1704 | 2021-08-20 Jakub Jelinek <jakub@redhat.com> |
1705 | ||
1706 | * c-parser.c (c_parser_omp_error): New function. | |
1707 | (c_parser_pragma): Handle PRAGMA_OMP_ERROR. | |
1708 | ||
1709 | 2021-08-20 Jakub Jelinek <jakub@redhat.com> | |
1710 | ||
1711 | * c-parser.c (c_parser_omp_clause_depend_sink): Reject spurious | |
1712 | comma at the end of list. | |
1713 | (c_parser_omp_requires): Likewise. | |
1714 | ||
b57fba5e GA |
1715 | 2021-08-19 Jakub Jelinek <jakub@redhat.com> |
1716 | ||
1717 | * c-parser.c (c_parser_omp_requires): Don't call | |
1718 | c_parser_peek_2nd_token and optionally consume token if current | |
1719 | token is CPP_EOF, CPP_PRAGMA_EOL or CPP_CLOSE_PAREN. | |
1720 | ||
6e529985 GA |
1721 | 2021-08-18 Jakub Jelinek <jakub@redhat.com> |
1722 | ||
1723 | * c-parser.c (c_parser_omp_nothing): New function. | |
1724 | (c_parser_pragma): Handle PRAGMA_OMP_NOTHING. | |
1725 | ||
1726 | 2021-08-18 Jakub Jelinek <jakub@redhat.com> | |
1727 | ||
1728 | * c-parser.c (c_parser_statement_after_labels): Add restart label | |
1729 | near the start of the function. If c_parser_pragma returns false, | |
1730 | goto restart. | |
1731 | (c_parser_pragma): For PRAGMA_OMP_CANCELLATION_POINT return what | |
1732 | c_parser_omp_cancellation_point returned. For PRAGMA_OMP_DECLARE | |
1733 | return what c_parser_omp_declare returned. Return true instead of | |
1734 | false after emitting errors that the directive is not allowed in | |
1735 | pragma_stmt context. | |
1736 | (c_parser_omp_ordered): Return true instead of | |
1737 | false after emitting errors that the directive is not allowed in | |
1738 | pragma_stmt context. | |
1739 | (c_parser_omp_target_update): Likewise. | |
1740 | (c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): | |
1741 | Change return type from tree to bool, return false if the | |
1742 | directive should be ignored in pragma_stmt contexts. | |
1743 | (c_parser_omp_target): Adjust callers of c_parser_omp_target_*_data, | |
1744 | return their result directly. | |
1745 | (c_parser_omp_cancellation_point): Change return type from void to | |
1746 | bool, return false if the directive should be ignored in pragma_stmt | |
1747 | contexts. | |
1748 | (c_parser_omp_declare): Likewise. | |
1749 | ||
2d14d64b GA |
1750 | 2021-08-17 Jakub Jelinek <jakub@redhat.com> |
1751 | ||
1752 | * c-parser.c (OMP_SCOPE_CLAUSE_MASK): Define. | |
1753 | (c_parser_omp_scope): New function. | |
1754 | (c_parser_omp_construct): Handle PRAGMA_OMP_SCOPE. | |
1755 | ||
72be20e2 GA |
1756 | 2021-08-12 Jakub Jelinek <jakub@redhat.com> |
1757 | ||
1758 | * c-parser.c (c_parser_omp_clause_name): Parse filter clause name. | |
1759 | (c_parser_omp_clause_filter): New function. | |
1760 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_FILTER. | |
1761 | (OMP_MASKED_CLAUSE_MASK): Define. | |
1762 | (c_parser_omp_masked): New function. | |
1763 | (c_parser_omp_parallel): Handle parallel masked. | |
1764 | (c_parser_omp_construct): Handle PRAGMA_OMP_MASKED. | |
1765 | * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_FILTER. | |
1766 | ||
1767 | 2021-08-12 Martin Uecker <muecker@gwdg.de> | |
1768 | ||
1769 | PR c/101838 | |
1770 | PR c/29970 | |
1771 | * c-typeck.c (c_expr_sizeof_type): Evaluate | |
1772 | size expressions for structs of variable size. | |
1773 | ||
1774 | 2021-08-12 Tobias Burnus <tobias@codesourcery.com> | |
1775 | ||
1776 | * c-parser.c (c_parser_omp_clause_proc_bind): Accept | |
1777 | 'primary' as alias for 'master'. | |
1778 | ||
3ae564ea GA |
1779 | 2021-08-10 Martin Uecker <muecker@gwdg.de> |
1780 | ||
1781 | PR c/29970 | |
1782 | * c-typeck.c (c_expr_sizeof_expr): Evaluate | |
1783 | size expressions for structs of variable size. | |
1784 | ||
f92f4778 GA |
1785 | 2021-08-06 Tamar Christina <tamar.christina@arm.com> |
1786 | ||
1787 | * c-decl.c (c_simulate_enum_decl): Pass vec<> by pointer. | |
1788 | * c-tree.h (c_simulate_enum_decl): Likewise. | |
1789 | ||
1790 | 2021-08-06 Martin Sebor <msebor@redhat.com> | |
1791 | ||
1792 | * c-parser.c (c_parser_declaration_or_fndef): Adjust by-value function | |
1793 | vec arguments to by-reference. | |
1794 | (c_finish_omp_declare_simd): Same. | |
1795 | (c_parser_compound_statement_nostart): Same. | |
1796 | (c_parser_for_statement): Same. | |
1797 | (c_parser_objc_methodprotolist): Same. | |
1798 | (c_parser_oacc_routine): Same. | |
1799 | (c_parser_omp_for_loop): Same. | |
1800 | (c_parser_omp_declare_simd): Same. | |
1801 | ||
419c6c68 GA |
1802 | 2021-07-21 Thomas Schwinge <thomas@codesourcery.com> |
1803 | Joseph Myers <joseph@codesourcery.com> | |
1804 | Cesar Philippidis <cesar@codesourcery.com> | |
1805 | ||
1806 | * c-parser.c (c_parser_omp_clause_name): Handle 'nohost'. | |
1807 | (c_parser_oacc_all_clauses): Handle 'PRAGMA_OACC_CLAUSE_NOHOST'. | |
1808 | (OACC_ROUTINE_CLAUSE_MASK): Add 'PRAGMA_OACC_CLAUSE_NOHOST'. | |
1809 | * c-typeck.c (c_finish_omp_clauses): Handle 'OMP_CLAUSE_NOHOST'. | |
1810 | ||
92d45509 GA |
1811 | 2021-07-20 Martin Sebor <msebor@redhat.com> |
1812 | ||
1813 | * c-tree.h (c_build_function_call_vec): Adjust by-value argument to | |
1814 | by-const-reference. | |
1815 | * c-typeck.c (c_build_function_call_vec): Same. | |
1816 | ||
d97d71a1 GA |
1817 | 2021-07-15 Martin Sebor <msebor@redhat.com> |
1818 | ||
1819 | PR c/101289 | |
1820 | PR c/97548 | |
1821 | * c-decl.c (get_parm_array_spec): Strip nops. | |
1822 | ||
6fba0eea GA |
1823 | 2021-07-06 Martin Sebor <msebor@redhat.com> |
1824 | ||
1825 | * c-objc-common.c (c_tree_printer): Remove support for %G and %K. | |
1826 | ||
7a60a6e8 GA |
1827 | 2021-07-02 Jakub Jelinek <jakub@redhat.com> |
1828 | ||
1829 | PR c/101297 | |
1830 | * c-parser.c (c_parser_omp_atomic): Consume comma only if it | |
1831 | appears before a CPP_NAME. | |
1832 | ||
90708f87 GA |
1833 | 2021-06-25 Martin Sebor <msebor@redhat.com> |
1834 | ||
1835 | * c-decl.c (pop_scope): Replace direct uses of TREE_NO_WARNING with | |
1836 | warning_suppressed_p, suppress_warning, and copy_no_warning. | |
1837 | (diagnose_mismatched_decls): Same. | |
1838 | (duplicate_decls): Same. | |
1839 | (grokdeclarator): Same. | |
1840 | (finish_function): Same. | |
1841 | (c_write_global_declarations_1): Same. | |
1842 | * c-fold.c (c_fully_fold_internal): Same. | |
1843 | * c-parser.c (c_parser_expr_no_commas): Same. | |
1844 | (c_parser_postfix_expression): Same. | |
1845 | * c-typeck.c (array_to_pointer_conversion): Same. | |
1846 | (function_to_pointer_conversion): Same. | |
1847 | (default_function_array_conversion): Same. | |
1848 | (convert_lvalue_to_rvalue): Same. | |
1849 | (default_conversion): Same. | |
1850 | (build_indirect_ref): Same. | |
1851 | (build_function_call_vec): Same. | |
1852 | (build_atomic_assign): Same. | |
1853 | (build_unary_op): Same. | |
1854 | (c_finish_return): Same. | |
1855 | (emit_side_effect_warnings): Same. | |
1856 | (c_finish_stmt_expr): Same. | |
1857 | (c_omp_clause_copy_ctor): Same. | |
1858 | ||
9aa8327e GA |
1859 | 2021-06-24 Jakub Jelinek <jakub@redhat.com> |
1860 | ||
1861 | PR c/101176 | |
1862 | * c-parser.c (c_parser_has_attribute_expression): Set source range for | |
1863 | the result. | |
1864 | ||
1865 | 2021-06-24 Jakub Jelinek <jakub@redhat.com> | |
1866 | ||
1867 | PR c/101171 | |
1868 | * c-typeck.c (build_c_cast): Don't call note_integer_operands on | |
1869 | error_mark_node. | |
1870 | ||
1871 | 2021-06-24 Jakub Jelinek <jakub@redhat.com> | |
1872 | ||
1873 | * c-parser.c (omp_split_clauses): Pass C_ORT_OMP_TARGET instead of | |
1874 | C_ORT_OMP for clauses on target construct. | |
1875 | (OMP_TARGET_CLAUSE_MASK): Add in_reduction clause. | |
1876 | (c_parser_omp_target): For non-combined target add | |
1877 | map (always, tofrom:) clauses for OMP_CLAUSE_IN_REDUCTION. Pass | |
1878 | C_ORT_OMP_TARGET to c_finish_omp_clauses. | |
1879 | * c-typeck.c (handle_omp_array_sections): Adjust ort handling | |
1880 | for addition of C_ORT_OMP_TARGET and simplify, mapping clauses are | |
1881 | never present on C_ORT_*DECLARE_SIMD. | |
1882 | (c_finish_omp_clauses): Likewise. Handle OMP_CLAUSE_IN_REDUCTION | |
1883 | on C_ORT_OMP_TARGET, set OMP_CLAUSE_MAP_IN_REDUCTION on | |
1884 | corresponding map clauses. | |
1885 | ||
2f080224 GA |
1886 | 2021-06-21 Jakub Jelinek <jakub@redhat.com> |
1887 | ||
1888 | PR inline-asm/100785 | |
1889 | * c-typeck.c (c_mark_addressable): Diagnose trying to make | |
1890 | bit-fields addressable. | |
1891 | ||
ede6c356 GA |
1892 | 2021-06-15 Robin Dapp <rdapp@linux.ibm.com> |
1893 | ||
1894 | * c-decl.c (merge_decls): Copy DECL_USER_ALIGN if DECL_ALIGN is | |
1895 | similar. | |
1896 | ||
8dc48181 GA |
1897 | 2021-06-14 Tobias Burnus <tobias@codesourcery.com> |
1898 | ||
1899 | PR c/100913 | |
1900 | * c-parser.c (c_parser_omp_clause_affinity): No need to set iterator | |
1901 | var in the error case. | |
1902 | ||
438aac59 GA |
1903 | 2021-06-07 Eric Botcazou <ebotcazou@adacore.com> |
1904 | ||
1905 | PR c/100920 | |
1906 | * c-typeck.c (convert_for_assignment): Test fndecl_built_in_p to | |
1907 | spot built-in functions. | |
1908 | ||
7d6987e9 GA |
1909 | 2021-06-06 Jakub Jelinek <jakub@redhat.com> |
1910 | ||
1911 | PR c/100902 | |
1912 | * c-parser.c (c_parser_omp_target): Call c_omp_adjust_map_clauses | |
1913 | even when target is combined with other constructs. | |
1914 | ||
1915 | 2021-06-06 Eric Botcazou <ebotcazou@adacore.com> | |
1916 | ||
1917 | PR c/100920 | |
1918 | * c-decl.c (finish_struct): Fix thinko in previous change. | |
1919 | * c-typeck.c (convert_for_assignment): Do not warn on pointer | |
1920 | assignment and initialization for storage order purposes if the | |
1921 | RHS is a call to a DECL_IS_MALLOC function. | |
1922 | ||
600f90cb GA |
1923 | 2021-06-04 Martin Sebor <msebor@redhat.com> |
1924 | ||
1925 | PR c/100783 | |
1926 | * c-objc-common.c (print_type): Handle erroneous types. | |
1927 | ||
440c8a0a GA |
1928 | 2021-06-03 Jakub Jelinek <jakub@redhat.com> |
1929 | ||
1930 | PR c++/100859 | |
1931 | * c-typeck.c (c_finish_omp_clauses): Move OMP_CLAUSE_AFFINITY | |
1932 | after depend only cases. | |
1933 | ||
ee682192 GA |
1934 | 2021-05-31 Richard Biener <rguenther@suse.de> |
1935 | ||
1936 | PR c++/88601 | |
1937 | * c-decl.c (names_builtin_p): Handle RID_BUILTIN_SHUFFLEVECTOR. | |
1938 | * c-parser.c (c_parser_postfix_expression): Likewise. | |
1939 | ||
48166757 GA |
1940 | 2021-05-28 Richard Biener <rguenther@suse.de> |
1941 | ||
1942 | PR c/100803 | |
1943 | * gimple-parser.c (c_parser_gimple_paren_condition): Diagnose | |
1944 | invalid if conditions. | |
1945 | ||
1946 | 2021-05-28 Jakub Jelinek <jakub@redhat.com> | |
1947 | ||
1948 | PR middle-end/99928 | |
1949 | * c-typeck.c (handle_omp_array_sections): Copy OMP_CLAUSE_MAP_IMPLICIT. | |
1950 | (c_finish_omp_clauses): Move not just OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT | |
1951 | marked clauses last, but also OMP_CLAUSE_MAP_IMPLICIT. Add | |
1952 | map_firstprivate_head bitmap, set it for GOMP_MAP_FIRSTPRIVATE_POINTER | |
1953 | maps and silently remove OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT if it is | |
1954 | present too. For OMP_CLAUSE_MAP_IMPLICIT silently remove the clause | |
1955 | if present in map_head, map_field_head or map_firstprivate_head | |
1956 | bitmaps. | |
1957 | ||
1958 | 2021-05-28 Tobias Burnus <tobias@codesourcery.com> | |
1959 | ||
1960 | * c-parser.c (c_parser_omp_clause_affinity): New. | |
1961 | (c_parser_omp_clause_name, c_parser_omp_variable_list, | |
1962 | c_parser_omp_all_clauses, OMP_TASK_CLAUSE_MASK): Handle affinity clause. | |
1963 | * c-typeck.c (handle_omp_array_sections_1, handle_omp_array_sections, | |
1964 | c_finish_omp_clauses): Likewise. | |
1965 | ||
01c59ef2 GA |
1966 | 2021-05-26 Eric Botcazou <ebotcazou@adacore.com> |
1967 | ||
1968 | PR c/100653 | |
1969 | * c-decl.c (finish_struct): Warn for a union containing an aggregate | |
1970 | field with a differing scalar storage order. | |
1971 | ||
2832d51b GA |
1972 | 2021-05-21 Jakub Jelinek <jakub@redhat.com> |
1973 | ||
1974 | PR middle-end/99928 | |
1975 | * c-typeck.c (c_finish_omp_clauses): Move firstprivate clauses with | |
1976 | OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT to the end of the chain. Don't error | |
1977 | if a decl is mentioned both in map clause and in such firstprivate | |
1978 | clause unless OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET is also set. | |
1979 | ||
65f32e5d GA |
1980 | 2021-05-19 Jakub Jelinek <jakub@redhat.com> |
1981 | ||
1982 | PR middle-end/99928 | |
1983 | * c-parser.c (c_parser_omp_master): Set OMP_MASTER_COMBINED on | |
1984 | master when combined with taskloop. | |
1985 | (c_parser_omp_parallel): Don't set OMP_PARALLEL_COMBINED on | |
1986 | parallel master when not combined with taskloop. | |
1987 | ||
a8daf9a1 GA |
1988 | 2021-05-18 Richard Biener <rguenther@suse.de> |
1989 | ||
1990 | PR c/100522 | |
1991 | * gimple-parser.c (c_parser_gimple_postfix_expression_after_primary): | |
1992 | Diagnose calls to non-functions. | |
1993 | (c_parser_gimple_statement): Diagnose unexpected assignment RHS. | |
1994 | ||
a7ffc1ef GA |
1995 | 2021-05-17 Richard Biener <rguenther@suse.de> |
1996 | ||
1997 | PR c/100625 | |
1998 | * gimple-parser.c (c_parser_gimple_label): Avoid building | |
1999 | a GIMPLE label with NULL label decl. | |
2000 | ||
f9af11c7 GA |
2001 | 2021-05-13 Martin Sebor <msebor@redhat.com> |
2002 | ||
2003 | PR c/100550 | |
2004 | * c-decl.c (get_parm_array_spec): Avoid erroneous VLA bounds. | |
2005 | ||
0ff3a0f2 GA |
2006 | 2021-05-12 Marcel Vollweiler <marcel@codesourcery.com> |
2007 | ||
2008 | * c-parser.c (c_parser_omp_clause_map): Support map-type-modifier | |
2009 | 'close'. | |
2010 | ||
aa891c56 GA |
2011 | 2021-05-10 Martin Liska <mliska@suse.cz> |
2012 | ||
2013 | * c-aux-info.c (affix_data_type): Use startswith | |
2014 | function instead of strncmp. | |
2015 | * c-typeck.c (build_function_call_vec): Likewise. | |
2016 | * gimple-parser.c (c_parser_gimple_parse_bb_spec): Likewise. | |
2017 | ||
62d87a32 GA |
2018 | 2021-05-07 Eric Botcazou <ebotcazou@adacore.com> |
2019 | ||
2020 | * c-typeck.c (build_unary_op) <ADDR_EXPR>: Do not issue an error | |
2021 | on the address of a pointer field in a record with reverse SSO. | |
2022 | ||
99e8df7a GA |
2023 | 2021-05-04 Tobias Burnus <tobias@codesourcery.com> |
2024 | ||
2025 | * c-typeck.c (c_finish_omp_clauses): Accept float + complex | |
2026 | for || and && reductions. | |
2027 | ||
3c8e539d GA |
2028 | 2021-04-29 Joseph Myers <joseph@codesourcery.com> |
2029 | ||
2030 | * c-typeck.c (function_types_compatible_p): For C2X, treat | |
2031 | unprototyped function as compatible with non-variadic prototyped | |
2032 | function even if some argument types are changed by the default | |
2033 | argument promotions. | |
2034 | ||
ee351f7f GA |
2035 | 2021-04-15 Martin Sebor <msebor@redhat.com> |
2036 | ||
2037 | PR c/99420 | |
2038 | PR c/99972 | |
2039 | * c-decl.c (pushdecl): Always propagate type attribute. | |
2040 | ||
2041 | 2021-04-15 Richard Sandiford <richard.sandiford@arm.com> | |
2042 | ||
2043 | PR c/98852 | |
2044 | * c-typeck.c (c_common_type): Do not drop attributes that | |
2045 | affect type identity. | |
2046 | ||
1d54b138 GA |
2047 | 2021-04-10 Jakub Jelinek <jakub@redhat.com> |
2048 | ||
2049 | PR c/99990 | |
2050 | * c-decl.c (finish_decl): Don't overwrite TREE_TYPE of | |
2051 | error_mark_node. | |
2052 | ||
4493b1c1 GA |
2053 | 2021-03-25 Jakub Jelinek <jakub@redhat.com> |
2054 | ||
2055 | PR c++/99565 | |
2056 | * c-typeck.c (build_conditional_expr): Pass OEP_ADDRESS_OF_SAME_FIELD | |
2057 | to operand_equal_p. | |
2058 | ||
5f256a70 GA |
2059 | 2021-03-19 Jakub Jelinek <jakub@redhat.com> |
2060 | ||
2061 | PR c/99588 | |
2062 | * c-typeck.c (mark_exp_read): Recognize what build_atomic_assign | |
2063 | with modifycode NOP_EXPR produces and mark the _Atomic var as read | |
2064 | if found. | |
2065 | (build_atomic_assign): For modifycode of NOP_EXPR, use COMPOUND_EXPRs | |
2066 | rather than STATEMENT_LIST. Otherwise call mark_exp_read on lhs. | |
2067 | Set TREE_SIDE_EFFECTS on the TARGET_EXPR. | |
2068 | ||
3c5b6d24 GA |
2069 | 2021-03-15 Tobias Burnus <tobias@codesourcery.com> |
2070 | ||
2071 | PR c++/99509 | |
2072 | * c-decl.c (finish_decl): For 'omp declare target implicit' vars, | |
2073 | ensure that the varpool node is marked as offloadable. | |
2074 | ||
ceae9533 GA |
2075 | 2021-03-05 Tobias Burnus <tobias@codesourcery.com> |
2076 | ||
2077 | PR c/99137 | |
2078 | * c-parser.c (c_parser_oacc_clause_async): Reject comma expressions. | |
2079 | ||
4028d01a GA |
2080 | 2021-02-24 Martin Sebor <msebor@redhat.com> |
2081 | ||
2082 | PR middle-end/97172 | |
2083 | * c-decl.c (free_attr_access_data): Clear attribute arg spec. | |
2084 | ||
bf81237e GA |
2085 | 2021-02-18 Jakub Jelinek <jakub@redhat.com> |
2086 | ||
2087 | PR c/99136 | |
2088 | * c-typeck.c (c_finish_return): Don't wrap retval into | |
2089 | EXCESS_PRECISION_EXPR in functions that return void. | |
2090 | ||
0c5cdb31 GA |
2091 | 2021-02-11 Marek Polacek <polacek@redhat.com> |
2092 | ||
2093 | * c-parser.c (c_parser_if_statement): Use vec_free. | |
2094 | ||
a19dd5e6 GA |
2095 | 2021-02-04 Martin Sebor <msebor@redhat.com> |
2096 | ||
2097 | PR c/97882 | |
2098 | * c-decl.c (locate_old_decl): Add type to diagnostic output. | |
2099 | (diagnose_mismatched_decls): Same. | |
2100 | (start_function): Introduce temporaries for better readability. | |
2101 | * c-typeck.c (comptypes_internal): Only consider complete enum | |
2102 | types in comparisons with integers. | |
2103 | ||
f7884fb1 GA |
2104 | 2021-02-01 Martin Sebor <msebor@redhat.com> |
2105 | ||
2106 | PR middle-end/97172 | |
2107 | * c-decl.c (free_attr_access_data): New function. | |
2108 | (c_parse_final_cleanups): Call free_attr_access_data. | |
2109 | ||
59cf67d1 GA |
2110 | 2021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com> |
2111 | ||
2112 | * c-parser.c (c_parser_omp_clause_detach): New. | |
2113 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_DETACH clause. | |
2114 | (OMP_TASK_CLAUSE_MASK): Add mask for PRAGMA_OMP_CLAUSE_DETACH. | |
2115 | * c-typeck.c (c_finish_omp_clauses): Handle PRAGMA_OMP_CLAUSE_DETACH | |
2116 | clause. Prevent use of detach with mergeable and overriding the | |
2117 | data sharing mode of the event handle. | |
2118 | ||
2f7f0d32 GA |
2119 | 2021-01-15 Jakub Jelinek <jakub@redhat.com> |
2120 | ||
2121 | * c-typeck.c (c_finish_omp_clauses): For reduction build array with | |
2122 | unqualified element type and then call c_build_qualified_type on the | |
2123 | ARRAY_TYPE. | |
2124 | ||
7d187e4f GA |
2125 | 2021-01-07 Richard Biener <rguenther@suse.de> |
2126 | ||
2127 | * gimple-parser.c (c_parser_gimple_compound_statement): Only | |
2128 | reallocate loop array if it is too small. | |
2129 | ||
eefe499f GA |
2130 | 2020-12-16 Martin Uecker <muecker@gwdg.de> |
2131 | ||
2132 | PR c/98047 | |
2133 | * c-typeck.c (build_modify_expr): Drop qualifiers. | |
2134 | ||
2135 | 2020-12-16 Martin Uecker <muecker@gwdg.de> | |
2136 | ||
2137 | PR c/98260 | |
2138 | * c-parser.c (c_parser_expression): Look into | |
2139 | nop expression when marking expressions as read. | |
2140 | ||
d52945ce GA |
2141 | 2020-12-14 Martin Liska <mliska@suse.cz> |
2142 | ||
2143 | PR sanitizer/98204 | |
2144 | * c-typeck.c (pointer_diff): Do not emit a top-level | |
2145 | sanitization. | |
2146 | (build_binary_op): Likewise. | |
2147 | ||
ca2bd949 GA |
2148 | 2020-12-09 Tobias Burnus <tobias@codesourcery.com> |
2149 | ||
2150 | * c-parser.c (c_parser_omp_allocate): New. | |
2151 | (c_parser_omp_construct): Call it. | |
2152 | ||
2153 | 2020-12-09 Richard Biener <rguenther@suse.de> | |
2154 | ||
2155 | PR c/98200 | |
2156 | * gimple-parser.c (c_parser_gimple_postfix_expression): Return | |
2157 | early on error. | |
2158 | ||
bc8a7013 GA |
2159 | 2020-12-07 Martin Uecker <muecker@gwdg.de> |
2160 | ||
2161 | PR c/97981 | |
2162 | * c-typeck.c (convert_lvalue_to_rvalue): Move the code | |
2163 | that drops qualifiers to the end of the function. | |
2164 | ||
d48df6f2 GA |
2165 | 2020-11-26 Martin Uecker <muecker@gwdg.de> |
2166 | ||
2167 | PR c/65455 | |
2168 | PR c/92935 | |
2169 | * c-parser.c (c_parser_declaration_or_fndef): Remove | |
2170 | redundant code to drop qualifiers of _Atomic types for __auto_type. | |
2171 | (c_parser_typeof_specifier): Do not drop qualifiers of _Atomic | |
2172 | types for __typeof__. | |
2173 | ||
1e2c9a27 GA |
2174 | 2020-11-24 Jakub Jelinek <jakub@redhat.com> |
2175 | ||
2176 | PR c/97958 | |
2177 | * c-parser.c (c_parser_binary_expression): For omp atomic binary | |
2178 | expressions, use make_node instead of build2 to avoid checking build2 | |
2179 | performs. | |
2180 | ||
8e6198d0 GA |
2181 | 2020-11-23 Joseph Myers <joseph@codesourcery.com> |
2182 | ||
2183 | PR c/95630 | |
2184 | * c-typeck.c (build_binary_op): Use pedwarn_c99 with OPT_Wpedantic | |
2185 | for comparisons of complete and incomplete pointers. | |
2186 | ||
7a97e2fc GA |
2187 | 2020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com> |
2188 | ||
2189 | * c-aux-info.c (gen_type): Support opaque types. | |
2190 | ||
82e5048e GA |
2191 | 2020-11-20 Martin Sebor <msebor@redhat.com> |
2192 | ||
2193 | PR middle-end/97879 | |
2194 | * c-decl.c (start_function): Set ATTR_FLAG_INTERNAL in flags. | |
2195 | ||
2196 | 2020-11-20 Jakub Jelinek <jakub@redhat.com> | |
2197 | ||
2198 | PR other/97911 | |
2199 | * Make-lang.in (c.serial): Change from goal to a variable. | |
2200 | (.PHONY): Drop c.serial. | |
2201 | ||
2202 | 2020-11-20 Martin Uecker <muecker@gwdg.de> | |
2203 | ||
2204 | * c-typeck.c (convert_lvalue_to_rvalue): Drop qualifiers. | |
2205 | ||
d62586ee GA |
2206 | 2020-11-19 Jakub Jelinek <jakub@redhat.com> |
2207 | ||
2208 | PR c/97860 | |
2209 | * c-decl.c (get_parm_array_spec): Bail out of nelts is | |
2210 | error_operand_p. | |
2211 | ||
25bb75f8 GA |
2212 | 2020-11-18 Jakub Jelinek <jakub@redhat.com> |
2213 | ||
2214 | * Make-lang.in (c.serial): New goal. | |
2215 | (.PHONY): Add c.serial c.prev. | |
2216 | (cc1$(exeext)): Call LINK_PROGRESS. | |
2217 | ||
77f67db2 GA |
2218 | 2020-11-13 Vladimir N. Makarov <vmakarov@redhat.com> |
2219 | ||
2220 | * c-parser.c (c_parser_asm_statement): Parse outputs for asm | |
2221 | goto too. | |
2222 | * c-typeck.c (build_asm_expr): Remove an assert checking output | |
2223 | absence for asm goto. | |
2224 | ||
2225 | 2020-11-13 Jakub Jelinek <jakub@redhat.com> | |
2226 | ||
2227 | * c-typeck.c (c_finish_omp_clauses): Don't clear | |
2228 | OMP_CLAUSE_REDUCTION_INSCAN unless reduction_seen == -2. | |
2229 | ||
2230 | 2020-11-13 Iain Sandoe <iain@sandoe.co.uk> | |
2231 | ||
2232 | PR objc/77404 | |
2233 | * c-parser.c (c_parser_objc_class_definition): Pass the | |
2234 | location of the class name to the interface declaration. | |
2235 | ||
bb622641 GA |
2236 | 2020-11-10 Strager Neds <strager.nds@gmail.com> |
2237 | ||
2238 | * c-decl.c (merge_decls): Use new overload of | |
2239 | set_decl_section_name. | |
2240 | ||
2241 | 2020-11-10 Chung-Lin Tang <cltang@codesourcery.com> | |
2242 | ||
2243 | * c-parser.c (c_parser_omp_target_data): Add use of | |
2244 | new c_omp_adjust_map_clauses function. Add GOMP_MAP_ATTACH_DETACH as | |
2245 | handled map clause kind. | |
2246 | (c_parser_omp_target_enter_data): Likewise. | |
2247 | (c_parser_omp_target_exit_data): Likewise. | |
2248 | (c_parser_omp_target): Likewise. | |
2249 | * c-typeck.c (handle_omp_array_sections): Adjust COMPONENT_REF case to | |
2250 | use GOMP_MAP_ATTACH_DETACH map kind for C_ORT_OMP region type. | |
2251 | (c_finish_omp_clauses): Adjust bitmap checks to allow struct decl and | |
2252 | same struct field access to co-exist on OpenMP construct. | |
2253 | ||
2da7ee05 GA |
2254 | 2020-11-07 Martin Uecker <muecker@gwdg.de> |
2255 | ||
2256 | * c-parser.c (c_parser_label): Implement mixing of labels and code. | |
2257 | (c_parser_all_labels): Likewise. | |
2258 | ||
44cab2d8 GA |
2259 | 2020-11-06 Iain Sandoe <iain@sandoe.co.uk> |
2260 | ||
2261 | * c-parser.c (c_parser_objc_at_property_declaration): | |
2262 | Improve parsing fidelity. Associate better location info | |
2263 | with @property attributes. Clean up the interface to | |
2264 | objc_add_property_declaration (). | |
2265 | ||
2266 | 2020-11-06 Nathan Sidwell <nathan@acm.org> | |
2267 | ||
2268 | * c-decl.c (diagnose_mismatched_decls): Rename | |
2269 | DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN. | |
2270 | (warn_if_shadowing, implicitly_declare, names_builtin_p) | |
2271 | (collect_source_refs): Likewise. | |
2272 | * c-typeck.c (inform_declaration, inform_for_arg) | |
2273 | (convert_for_assignment): Likewise. | |
2274 | ||
2275 | 2020-11-06 Tobias Burnus <tobias@codesourcery.com> | |
2276 | ||
2277 | * c-parser.c (c_parser_omp_atomic): Add openacc parameter and update | |
2278 | OpenACC matching. | |
2279 | (c_parser_omp_construct): Update call. | |
2280 | ||
35c125cb GA |
2281 | 2020-11-04 Jakub Jelinek <jakub@redhat.com> |
2282 | ||
2283 | PR c++/97670 | |
2284 | * c-typeck.c (c_finish_omp_clauses): Look through array reductions to | |
2285 | find underlying decl to clear in the aligned_head bitmap. | |
2286 | ||
2287 | 2020-11-04 Joseph Myers <joseph@codesourcery.com> | |
2288 | ||
2289 | * c-decl.c (handle_nodiscard_attribute): New. | |
2290 | (std_attribute_table): Add nodiscard. | |
2291 | * c-parser.c (c_parser_std_attribute): Expect argument to | |
2292 | nodiscard attribute to be a string. Do not special-case ignoring | |
2293 | nodiscard. | |
2294 | * c-typeck.c (maybe_warn_nodiscard): New. | |
2295 | (build_compound_expr, emit_side_effect_warnings): Call | |
2296 | maybe_warn_nodiscard. | |
2297 | (c_process_expr_stmt, c_finish_stmt_expr): Also call | |
2298 | emit_side_effect_warnings if warn_unused_result. | |
2299 | ||
4f0606fe GA |
2300 | 2020-10-29 Asher Gordon <AsDaGo@posteo.net> |
2301 | ||
2302 | * c-typeck.c (free_all_tagged_tu_seen_up_to): Replace free | |
2303 | with XDELETE. | |
2304 | (finish_init): Likewise. | |
2305 | (pop_init_level): Likewise. | |
2306 | ||
e93aae4a GA |
2307 | 2020-10-28 Joseph Myers <joseph@codesourcery.com> |
2308 | ||
2309 | * c-decl.c (store_parm_decls_newstyle): Use pedwarn_c11 not | |
2310 | error_at for omitted parameter name. | |
2311 | ||
2312 | 2020-10-28 Jakub Jelinek <jakub@redhat.com> | |
2313 | ||
2314 | * c-parser.c (c_parser_omp_clause_name): Handle allocate. | |
2315 | (c_parser_omp_clause_allocate): New function. | |
2316 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_ALLOCATE. | |
2317 | (OMP_FOR_CLAUSE_MASK, OMP_SECTIONS_CLAUSE_MASK, | |
2318 | OMP_PARALLEL_CLAUSE_MASK, OMP_SINGLE_CLAUSE_MASK, | |
2319 | OMP_TASK_CLAUSE_MASK, OMP_TASKGROUP_CLAUSE_MASK, | |
2320 | OMP_DISTRIBUTE_CLAUSE_MASK, OMP_TEAMS_CLAUSE_MASK, | |
2321 | OMP_TARGET_CLAUSE_MASK, OMP_TASKLOOP_CLAUSE_MASK): Add | |
2322 | PRAGMA_OMP_CLAUSE_ALLOCATE. | |
2323 | * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_ALLOCATE. | |
2324 | ||
89bb01e7 GA |
2325 | 2020-10-27 Joseph Myers <joseph@codesourcery.com> |
2326 | ||
2327 | * c-parser.c (c_parser_std_attribute_specifier): Allow duplicate | |
2328 | standard attributes. | |
2329 | ||
efe71fcc GA |
2330 | 2020-10-23 Marek Polacek <polacek@redhat.com> |
2331 | ||
2332 | PR c++/91741 | |
2333 | * c-parser.c (c_parser_binary_expression): Implement -Wsizeof-array-div. | |
2334 | (c_parser_postfix_expression): Set PAREN_SIZEOF_EXPR. | |
2335 | (c_parser_expr_list): Handle PAREN_SIZEOF_EXPR like SIZEOF_EXPR. | |
2336 | * c-tree.h (char_type_p): Declare. | |
2337 | * c-typeck.c (char_type_p): No longer static. | |
2338 | ||
2339 | 2020-10-23 Martin Sebor <msebor@redhat.com> | |
2340 | ||
2341 | PR middle-end/97552 | |
2342 | * c-decl.c (get_parm_array_spec): Handle static VLA parameters. | |
2343 | ||
2fe5b7d1 GA |
2344 | 2020-09-19 Martin Sebor <msebor@redhat.com> |
2345 | ||
2346 | PR c/50584 | |
2347 | * c-decl.c (lookup_last_decl): Define new function. | |
2348 | (c_decl_attributes): Call it. | |
2349 | (start_decl): Add argument and use it. | |
2350 | (finish_decl): Call build_attr_access_from_parms and decl_attributes. | |
2351 | (get_parm_array_spec): Define new function. | |
2352 | (push_parm_decl): Call get_parm_array_spec. | |
2353 | (start_function): Call warn_parm_array_mismatch. Build attribute | |
2354 | access and add it to current function. | |
2355 | * c-parser.c (c_parser_declaration_or_fndef): Diagnose mismatches | |
2356 | in forms of array parameters. | |
2357 | * c-tree.h (start_decl): Add argument. | |
2358 | ||
2359 | 2020-09-19 Sandra Loosemore <sandra@codesourcery.com> | |
2360 | ||
2361 | * c-decl.c (c_break_label, c_cont_label): Delete, and replace | |
2362 | with... | |
2363 | (in_statement): New. | |
2364 | (start_function): Adjust for above change. | |
2365 | (c_push_function_context, c_pop_function_context): Likewise. | |
2366 | * c-lang.h (struct language_function): Likewise. | |
2367 | * c-objc-common.h (LANG_HOOKS_BLOCK_MAY_FALLTHRU): Define. | |
2368 | * c-parser.c (objc_foreach_break_label, objc_foreach_continue_label): | |
2369 | New. | |
2370 | (c_parser_statement_after_labels): Adjust calls to c_finish_bc_stmt. | |
2371 | (c_parser_switch_statement): Adjust break/switch context handling | |
2372 | and calls to renamed functions. | |
2373 | (c_parser_while_statement): Adjust break/switch context handling and | |
2374 | build a WHILE_STMT. | |
2375 | (c_parser_do_statement): Ditto, with DO_STMT respectively. | |
2376 | (c_parser_for_statement): Ditto, with FOR_STMT respectively. | |
2377 | (c_parser_omp_for_loop): Adjust break/switch context handling. | |
2378 | * c-tree.h (c_break_label, c_cont_label): Delete. | |
2379 | (IN_SWITCH_STMT, IN_ITERATION_STMT): Define. | |
2380 | (IN_OMP_BLOCK, IN_OMP_FOR, IN_OBJC_FOREACH): Define. | |
2381 | (in_statement, switch_statement_break_seen_p): Declare. | |
2382 | (c_start_case, c_finish_case): Renamed to... | |
2383 | (c_start_switch, c_finish_switch). | |
2384 | (c_finish_bc_stmt): Adjust arguments. | |
2385 | * c-typeck.c (build_function_call_vec): Don't try to print | |
2386 | statements with %qE format. | |
2387 | (struct c_switch): Rename switch_expr field to switch_stmt. | |
2388 | Add break_stmt_seen_p field. | |
2389 | (c_start_case): Rename to c_start_switch. Build a SWITCH_STMT | |
2390 | instead of a SWITCH_EXPR. Update for changes to struct c_switch. | |
2391 | (do_case): Update for changes to struct c_switch. | |
2392 | (c_finish_case): Rename to c_finish_switch. Update for changes to | |
2393 | struct c_switch and change of representation from SWITCH_EXPR to | |
2394 | SWITCH_STMT. | |
2395 | (c_finish_loop): Delete. | |
2396 | (c_finish_bc_stmt): Update to reflect changes to break/continue | |
2397 | state representation. Build a BREAK_STMT or CONTINUE_STMT instead | |
2398 | of a GOTO_EXPR except for objc foreach loops. | |
2399 | ||
e1a4a8a0 GA |
2400 | 2020-09-01 Jakub Jelinek <jakub@redhat.com> |
2401 | ||
2402 | PR c++/96867 | |
2403 | * c-typeck.c (handle_omp_array_sections_1): Test C_ARRAY_PARAMETER | |
2404 | only on PARM_DECLs. | |
2405 | ||
8f7ea26a GA |
2406 | 2020-08-28 Martin Sebor <msebor@redhat.com> |
2407 | ||
2408 | PR c/96596 | |
2409 | * c-decl.c (match_builtin_function_types): Avoid dealing with erroneous | |
2410 | argument type. | |
2411 | ||
8b394f01 GA |
2412 | 2020-08-27 Martin Liska <mliska@suse.cz> |
2413 | ||
2414 | * gimple-parser.c (c_parser_gimple_compound_statement): Set exact argument of a vector | |
2415 | growth function to true. | |
2416 | ||
db0f6efe GA |
2417 | 2020-08-25 Tobias Burnus <tobias@codesourcery.com> |
2418 | ||
2419 | PR c/96678 | |
2420 | * c-typeck.c (handle_omp_array_sections_1): Talk about | |
2421 | array function parameter in the error message. | |
2422 | ||
5c265693 GA |
2423 | 2020-08-18 Jakub Jelinek <jakub@redhat.com> |
2424 | ||
2425 | PR c/96571 | |
2426 | * c-parser.c (c_parser_generic_selection): Change match_found from bool | |
2427 | to int, holding index of the match. Call mark_exp_read on the selector | |
2428 | expression and on expressions other than the selected one. | |
2429 | ||
4967ca2f GA |
2430 | 2020-08-01 Richard Sandiford <richard.sandiford@arm.com> |
2431 | ||
2432 | PR c/96377 | |
2433 | * c-typeck.c (process_init_element): Split test for whether to | |
2434 | recurse into a record, union or array into... | |
2435 | (initialize_elementwise_p): ...this new function. Don't recurse | |
2436 | into a vector type if the initialization value is also a vector. | |
2437 | ||
48cc2e46 GA |
2438 | 2020-07-31 Richard Biener <rguenther@suse.de> |
2439 | ||
2440 | PR debug/96383 | |
2441 | * c-objc-common.h (LANG_HOOKS_FINALIZE_EARLY_DEBUG): | |
2442 | Define to c_common_finalize_early_debug. | |
2443 | ||
3ea9abca GA |
2444 | 2020-07-22 Tobias Burnus <tobias@codesourcery.com> |
2445 | ||
2446 | * c-parser.c (c_parser_omp_clause_hint): Require nonnegative hint clause. | |
2447 | (c_parser_omp_critical): Permit hint(0) clause without named critical. | |
2448 | (c_parser_omp_construct): Don't assert if error_mark_node is returned. | |
2449 | ||
30430061 GA |
2450 | 2020-07-21 Sunil K Pandey <skpgkp2@gmail.com> |
2451 | ||
2452 | PR target/95237 | |
2453 | * c-decl.c (finish_decl): Call target hook | |
2454 | lower_local_decl_alignment to lower local decl alignment. | |
2455 | ||
3f8ca9cb GA |
2456 | 2020-07-09 Julian Brown <julian@codesourcery.com> |
2457 | Thomas Schwinge <thomas@codesourcery.com> | |
2458 | ||
2459 | PR middle-end/95270 | |
2460 | * c-typeck.c (c_finish_omp_clauses): Set OMP_CLAUSE_SIZE (bias) to zero | |
2461 | for standalone attach/detach clauses. | |
2462 | ||
a82c4c4c | 2463 | 2020-07-08 Eric Botcazou <ebotcazou@adacore.com> |
50873cc5 GA |
2464 | |
2465 | * c-typeck.c (convert_for_assignment): If -Wscalar-storage-order is | |
2466 | set, warn for conversion between pointers that point to incompatible | |
2467 | scalar storage orders. | |
2468 | ||
f60ee68d GA |
2469 | 2020-07-07 Kaipeng Zhou <zhoukaipeng3@huawei.com> |
2470 | ||
2471 | * c-parser.c (c_parser_statement_after_labels): Pass correct | |
2472 | parameters to c_parser_do_statement. | |
2473 | ||
56638b9b GA |
2474 | 2020-06-16 Jakub Jelinek <jakub@redhat.com> |
2475 | ||
2476 | * c-parser.c (c_parser_expr_no_commas): Save, clear and restore | |
2477 | c_in_omp_for. | |
2478 | (c_parser_omp_for_loop): Set c_in_omp_for around some calls to avoid | |
2479 | premature c_fully_fold. Defer explicit c_fully_fold calls to after | |
2480 | c_finish_omp_for. | |
2481 | * c-tree.h (c_in_omp_for): Declare. | |
2482 | * c-typeck.c (c_in_omp_for): Define. | |
2483 | (build_modify_expr): Avoid c_fully_fold if c_in_omp_for. | |
2484 | (digest_init): Likewise. | |
2485 | (build_binary_op): Likewise. | |
2486 | ||
2487 | 2020-06-16 Jakub Jelinek <jakub@redhat.com> | |
2488 | ||
2489 | * c-parser.c (c_parser_omp_clause_schedule): Reject modifier separated | |
2490 | from kind by comma rather than colon. | |
2491 | ||
1a59f3db GA |
2492 | 2020-06-05 Mark Wielaard <mark@klomp.org> |
2493 | ||
2494 | * c-decl.c (implicit_decl_warning): When warned and olddecl is | |
2495 | an undeclared builtin, then add a fixit header hint, if found. | |
2496 | (implicitly_declare): Add OPT_Wbuiltin_declaration_mismatch to | |
2497 | warning_at about implicit builtin declaration type mismatch. | |
2498 | ||
9a5b7438 GA |
2499 | 2020-06-03 Mark Wielaard <mark@klomp.org> |
2500 | ||
2501 | * c-parser.c (struct c_parser): Add seen_string_literal | |
2502 | bitfield. | |
2503 | (c_parser_consume_token): Reset seen_string_literal. | |
2504 | (c_parser_error_richloc): Add name_hint if seen_string_literal | |
2505 | and next token is a CPP_NAME and we have a missing header | |
2506 | suggestion for the name. | |
2507 | (c_parser_string_literal): Set seen_string_literal. | |
2508 | ||
2509 | 2020-06-03 Mark Wielaard <mark@klomp.org> | |
2510 | ||
2511 | * c-parser.c (c_parser_postfix_expression_after_primary): Add | |
2512 | scope with matching_parens after CPP_OPEN_PAREN. | |
2513 | ||
2514 | 2020-06-03 Tobias Burnus <tobias@codesourcery.com> | |
2515 | ||
2516 | * c-objc-common.h (LANG_HOOKS_OMP_PREDETERMINED_MAPPING): Redefine. | |
2517 | ||
53ffb43a GA |
2518 | 2020-05-28 Nicolas Bértolo <nicolasbertolo@gmail.com> |
2519 | ||
2520 | * Make-lang.in: Remove extra slash. | |
2521 | ||
8f66f175 ML |
2522 | 2020-05-19 Martin Liska <mliska@suse.cz> |
2523 | ||
2524 | * c-parser.c: Fix typo. | |
2525 | ||
49ddde69 JJ |
2526 | 2020-05-14 Jakub Jelinek <jakub@redhat.com> |
2527 | ||
2528 | * c-parser.c (c_parser_omp_target): Set cfun->has_omp_target. | |
2529 | ||
eb72dc66 RB |
2530 | 2020-05-07 Richard Biener <rguenther@suse.de> |
2531 | ||
2532 | PR middle-end/94703 | |
2533 | * gimple-parser.c (c_parser_parse_ssa_name): Do not set | |
2534 | DECL_GIMPLE_REG_P. | |
2535 | ||
bf915591 JJ |
2536 | 2020-04-30 Jakub Jelinek <jakub@redhat.com> |
2537 | ||
2538 | PR c/94842 | |
2539 | * c-decl.c (set_labels_context_r): In addition to context-less | |
2540 | LABEL_DECLs adjust also LABEL_DECLs with context equal to | |
2541 | parent function if any. | |
2542 | (store_parm_decls): Adjust comment. | |
2543 | ||
e1113ffb JJ |
2544 | 2020-04-19 Jakub Jelinek <jakub@redhat.com> |
2545 | ||
2546 | PR objc/94637 | |
2547 | * c-parser.c (c_parser_objc_selector_arg): Handle CPP_SCOPE like | |
2548 | two CPP_COLON tokens. | |
2549 | ||
2e389749 JJ |
2550 | 2020-04-17 Jakub Jelinek <jakub@redhat.com> |
2551 | ||
2552 | PR other/94629 | |
2553 | * c-parser.c (c_parser_oacc_routine): Remove redundant assignment | |
2554 | to data.clauses. | |
2555 | ||
2dc9294c JJ |
2556 | 2020-04-15 Jakub Jelinek <jakub@redhat.com> |
2557 | ||
2558 | PR c/94593 | |
2559 | * c-parser.c (c_parser_pragma) <case PRAGMA_OMP_REQUIRES>: Reject | |
2560 | requires directive when not at file scope. | |
2561 | ||
13e41d8b TB |
2562 | 2020-04-08 Tobias Burnus <tobias@codesourcery.com> |
2563 | ||
2564 | PR middle-end/94120 | |
2565 | * c-decl.c (c_check_in_current_scope): New function. | |
2566 | * c-tree.h (c_check_in_current_scope): Declare it. | |
2567 | * c-parser.c (c_parser_oacc_declare): Add check that variables | |
2568 | are declared in the same scope as the directive. Fix handling | |
2569 | of namespace vars. | |
2570 | ||
4df50a05 JJ |
2571 | 2020-04-07 Jakub Jelinek <jakub@redhat.com> |
2572 | ||
2573 | PR c++/94512 | |
2574 | * c-parser.c (c_parser_omp_parallel): Set OMP_PARALLEL_COMBINED | |
2575 | if c_parser_omp_master succeeded. | |
2576 | ||
5db9e893 JJ |
2577 | 2020-03-23 Jakub Jelinek <jakub@redhat.com> |
2578 | ||
2579 | PR gcov-profile/94029 | |
2580 | PR c/94239 | |
2581 | * c-parser.c (c_parser_declaration_or_fndef): Initialize endloc to | |
2582 | the function_start_locus location. Don't do that afterwards for the | |
2583 | __GIMPLE body parsing. | |
2584 | ||
9def91e9 JJ |
2585 | 2020-03-19 Jakub Jelinek <jakub@redhat.com> |
2586 | ||
2587 | PR gcov-profile/94029 | |
2588 | * c-tree.h (finish_function): Add location_t argument defaulted to | |
2589 | input_location. | |
2590 | * c-parser.c (c_parser_compound_statement): Add endlocp argument and | |
2591 | set it to the locus of closing } if non-NULL. | |
2592 | (c_parser_compound_statement_nostart): Return locus of closing }. | |
2593 | (c_parser_parse_rtl_body): Likewise. | |
2594 | (c_parser_declaration_or_fndef): Propagate locus of closing } to | |
2595 | finish_function. | |
2596 | * c-decl.c (finish_function): Add end_loc argument, use it instead of | |
2597 | input_location to set function_end_locus. | |
2598 | ||
046c5890 JJ |
2599 | 2020-03-17 Jakub Jelinek <jakub@redhat.com> |
2600 | ||
2601 | PR c/94172 | |
2602 | * c-tree.h (C_TYPE_INCOMPLETE_VARS): Define to TYPE_LANG_SLOT_1 | |
2603 | instead of TYPE_VFIELD, and support it on {RECORD,UNION,ENUMERAL}_TYPE. | |
2604 | (TYPE_ACTUAL_ARG_TYPES): Check that it is only used on FUNCTION_TYPEs. | |
2605 | * c-decl.c (pushdecl): Push C_TYPE_INCOMPLETE_VARS also to | |
2606 | ENUMERAL_TYPEs. | |
2607 | (finish_incomplete_vars): New function, moved from finish_struct. Use | |
2608 | relayout_decl instead of layout_decl. | |
2609 | (finish_struct): Remove obsolete comment about C_TYPE_INCOMPLETE_VARS | |
2610 | being TYPE_VFIELD. Use finish_incomplete_vars. | |
2611 | (finish_enum): Clear C_TYPE_INCOMPLETE_VARS. Call | |
2612 | finish_incomplete_vars. | |
2613 | * c-typeck.c (c_build_qualified_type): Clear C_TYPE_INCOMPLETE_VARS | |
2614 | also on ENUMERAL_TYPEs. | |
2615 | ||
c015ff8c JJ |
2616 | 2020-03-16 Jakub Jelinek <jakub@redhat.com> |
2617 | ||
2618 | PR c/94179 | |
2619 | * c-fold.c (c_fully_fold_internal): Handle MEM_REF. | |
2620 | ||
f2e9fe5f MS |
2621 | 2020-03-13 Martin Sebor <msebor@redhat.com> |
2622 | ||
2623 | PR c/94040 | |
2624 | * c-decl.c (builtin_structptr_type_count): New constant. | |
2625 | (match_builtin_function_types): Reject decls that are incompatible | |
2626 | in types pointed to by pointers. | |
2627 | (diagnose_mismatched_decls): Adjust comments. | |
2628 | ||
c9d70946 JM |
2629 | 2020-03-05 Joseph Myers <joseph@codesourcery.com> |
2630 | ||
2631 | PR c/93577 | |
2632 | * c-typeck.c (pop_init_level): Do not diagnose initializers as | |
2633 | empty when initialized type is error_mark_node. | |
2634 | (set_designator, process_init_element): Ignore initializers for | |
2635 | elements of a variable-size type or of error_mark_node. | |
2636 | ||
726e292d MS |
2637 | 2020-03-01 Martin Sebor <msebor@redhat.com> |
2638 | ||
2639 | PR middle-end/93926 | |
2640 | * c-decl.c (types_close_enough_to_match): New function. | |
2641 | (match_builtin_function_types): | |
2642 | (diagnose_mismatched_decls): Add missing inform call to a warning. | |
2643 | ||
a499c2f8 MS |
2644 | 2020-03-01 Martin Sebor <msebor@redhat.com> |
2645 | ||
2646 | PR c/93812 | |
2647 | * c-typeck.c (build_functype_attribute_variant): New function. | |
2648 | (composite_type): Call it. | |
2649 | ||
9c3da8cc JJ |
2650 | 2020-02-25 Jakub Jelinek <jakub@redhat.com> |
2651 | ||
2652 | PR other/93912 | |
2653 | * gimple-parser.c (c_parser_gimple_parse_bb_spec_edge_probability): | |
2654 | Rename last argument from probablity to probability. | |
2655 | ||
bacdd5e9 JJ |
2656 | 2020-02-13 Jakub Jelinek <jakub@redhat.com> |
2657 | ||
2658 | PR c/93576 | |
2659 | * c-decl.c (grokdeclarator): If this_size_varies, only push size into | |
2660 | *expr if it has side effects. | |
2661 | ||
f9eb0973 JL |
2662 | 2020-01-30 Jeff Law <law@redhat.com> |
2663 | ||
2664 | PR c/88660 | |
2665 | * c-parser.c (c_parser_switch_statement): Make sure to request | |
2666 | marking the switch expr as used. | |
2667 | ||
ac68e287 JM |
2668 | 2020-01-22 Joseph Myers <joseph@codesourcery.com> |
2669 | ||
2670 | PR c/93348 | |
2671 | * c-typeck.c (build_c_cast): Call remove_c_maybe_const_expr on | |
2672 | argument with integer operands. | |
2673 | ||
852f0ae8 KK |
2674 | 2020-01-16 Kerem Kat <keremkat@gmail.com> |
2675 | ||
2676 | PR c/92833 | |
2677 | * c-parser.c (c_parser_consume_token): Fix peeked token stack pop | |
2678 | to support 4 available tokens. | |
2679 | ||
e2346a33 JM |
2680 | 2020-01-15 Joseph Myers <joseph@codesourcery.com> |
2681 | ||
2682 | PR c/93072 | |
2683 | * c-decl.c (pushdecl): Use TREE_PUBLIC, not DECL_EXTERNAL, to | |
2684 | determine whether to set DECL_CONTEXT. | |
2685 | ||
3d77686d JM |
2686 | 2020-01-13 Joseph Myers <joseph@codesourcery.com> |
2687 | ||
2688 | PR c/93241 | |
2689 | * c-typeck.c (build_c_cast): Check for expressions with integer | |
2690 | operands that can occur in an unevaluated part of an integer | |
2691 | constant expression and call note_integer_operands as needed. | |
2692 | ||
f74c4b2c RB |
2693 | 2019-01-08 Richard Biener <rguenther@suse.de> |
2694 | ||
2695 | PR middle-end/93199 | |
2696 | * gimple-parser.c (c_parser_parse_gimple_body): Remove __PHI IFN | |
2697 | permanently. | |
2698 | ||
8d9254fc JJ |
2699 | 2020-01-01 Jakub Jelinek <jakub@redhat.com> |
2700 | ||
2701 | Update copyright years. | |
2702 | ||
39292e25 EB |
2703 | 2019-12-20 Eric Botcazou <ebotcazou@adacore.com> |
2704 | ||
2705 | * c-decl.c (collect_source_ref_cb): Delete. | |
2706 | (for_each_global_decl): Rename into... | |
2707 | (collect_source_refs): ...this. Call collect_source_ref directly. | |
2708 | (c_parse_final_cleanups): Always call collect_source_ref on the main | |
2709 | input filename. | |
2710 | ||
519d7496 JB |
2711 | 2019-12-19 Julian Brown <julian@codesourcery.com> |
2712 | Cesar Philippidis <cesar@codesourcery.com> | |
2713 | ||
2714 | * c-parser.c (c_parser_omp_clause_name): Add parsing of attach and | |
2715 | detach clauses. | |
2716 | (c_parser_omp_variable_list): Add ALLOW_DEREF optional parameter. | |
2717 | Allow deref (->) in variable lists if true. | |
2718 | (c_parser_omp_var_list_parens): Add ALLOW_DEREF optional parameter. | |
2719 | Pass to c_parser_omp_variable_list. | |
2720 | (c_parser_oacc_data_clause): Support attach and detach clauses. Update | |
2721 | call to c_parser_omp_variable_list. | |
2722 | (c_parser_oacc_all_clauses): Support attach and detach clauses. | |
2723 | (OACC_DATA_CLAUSE_MASK, OACC_ENTER_DATA_CLAUSE_MASK, | |
2724 | OACC_KERNELS_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK, | |
2725 | OACC_SERIAL_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_ATTACH. | |
2726 | (OACC_EXIT_DATA_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_DETACH. | |
2727 | * c-typeck.c (handle_omp_array_sections_1): Reject subarrays for attach | |
2728 | and detach. Support deref. | |
2729 | (handle_omp_array_sections): Use GOMP_MAP_ATTACH_DETACH instead of | |
2730 | GOMP_MAP_ALWAYS_POINTER for OpenACC. | |
2731 | (c_oacc_check_attachments): New function. | |
2732 | (c_finish_omp_clauses): Check attach/detach arguments for being | |
2733 | pointers using above. Support deref. | |
2734 | ||
a6163563 JB |
2735 | 2019-12-19 Julian Brown <julian@codesourcery.com> |
2736 | Maciej W. Rozycki <macro@codesourcery.com> | |
2737 | Tobias Burnus <tobias@codesourcery.com> | |
2738 | Thomas Schwinge <thomas@codesourcery.com> | |
2739 | ||
2740 | * c-parser.c (c_parser_omp_clause_name): Support no_create. | |
2741 | (c_parser_oacc_data_clause): Likewise. | |
2742 | (c_parser_oacc_all_clauses): Likewise. | |
2743 | (OACC_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK) | |
2744 | (OACC_PARALLEL_CLAUSE_MASK, OACC_SERIAL_CLAUSE_MASK): Add | |
2745 | PRAGMA_OACC_CLAUSE_NO_CREATE. | |
2746 | * c-typeck.c (handle_omp_array_sections): Support | |
2747 | GOMP_MAP_NO_ALLOC. | |
2748 | ||
d68f5d45 DM |
2749 | 2019-12-09 David Malcolm <dmalcolm@redhat.com> |
2750 | ||
2751 | * c-objc-common.c (range_label_for_type_mismatch::get_text): | |
2752 | Replace label_text ctor calls. | |
2753 | ||
4691bf46 JM |
2754 | 2019-12-04 Joseph Myers <joseph@codesourcery.com> |
2755 | ||
2756 | PR c/36941 | |
2757 | PR c/88827 | |
2758 | * c-typeck.c (convert_lvalue_to_rvalue): Call | |
2759 | require_complete_type for arguments not of void types. | |
2760 | (build_indirect_ref): Do not diagnose dereferencing pointers to | |
2761 | incomplete types. | |
2762 | * c-tree.h (C_TYPE_ERROR_REPORTED): Remove. | |
2763 | ||
85d11957 JM |
2764 | 2019-12-03 Joseph Myers <joseph@codesourcery.com> |
2765 | ||
2766 | PR c/88704 | |
2767 | * c-decl.c (store_parm_decls_oldstyle): Diagnose use of [*] in | |
2768 | old-style parameter definitions. | |
2769 | ||
4569f8b3 SL |
2770 | 2019-12-01 Sandra Loosemore <sandra@codesourcery.com> |
2771 | ||
2772 | PR target/92499 | |
2773 | ||
2774 | * c-decl.c (flexible_array_type_p): Move to common code. | |
2775 | ||
65ef05d0 RS |
2776 | 2019-11-30 Richard Sandiford <richard.sandiford@arm.com> |
2777 | ||
2778 | * c-decl.c (start_decl): Allow initialization of variables whose | |
2779 | size is a POLY_INT_CST. | |
2780 | (finish_decl): Use verify_type_context to check whether the target | |
2781 | allows variables with a particular type to have static or thread-local | |
2782 | storage duration. Don't raise a second error if such variables do | |
2783 | not have a constant size. | |
2784 | (grokdeclarator): Use verify_type_context to check whether the | |
2785 | target allows fields or array elements to have a particular type. | |
2786 | * c-typeck.c (pointer_diff): Use verify_type_context to test whether | |
2787 | the target allows pointer difference for the types involved. | |
2788 | (build_unary_op): Likewise for pointer increment and decrement. | |
2789 | ||
34b43828 JM |
2790 | 2019-11-29 Joseph Myers <joseph@codesourcery.com> |
2791 | ||
2792 | * c-parser.c (struct c_parser): Add members raw_tokens and | |
2793 | raw_tokens_used. | |
2794 | (c_lex_one_token): Add argument raw. Handle lexing raw tokens and | |
2795 | using previously-lexed raw tokens. | |
2796 | (c_parser_peek_nth_token_raw) | |
2797 | (c_parser_check_balanced_raw_token_sequence): New functions. | |
2798 | (c_parser_nth_token_starts_std_attributes): Use | |
2799 | c_parser_check_balanced_raw_token_sequence for Objective-C. | |
2800 | ||
5b8d9367 JM |
2801 | 2019-11-25 Joseph Myers <joseph@codesourcery.com> |
2802 | ||
2803 | PR c/91985 | |
2804 | * c-decl.c (finish_declspecs): Use int instead of decimal | |
2805 | floating-point types if decimal floating-point not supported. | |
2806 | ||
1723e1be JM |
2807 | 2019-11-25 Joseph Myers <joseph@codesourcery.com> |
2808 | ||
2809 | * c-tree.h (struct c_declarator): Use a structure for id member. | |
2810 | * c-decl.c (grokdeclarator): Extract attributes from cdk_id | |
2811 | declarators at the start, not when handling individual declarators | |
2812 | later. Use u.id.id instead of u.id. | |
2813 | (grokfield): Use u.id.id instead of u.id. | |
2814 | (build_id_declarator): Set u.id.id and u.id.attrs. | |
2815 | (finish_declspecs): Handle postfix attributes in case of typedef | |
2816 | name or typeof used. | |
2817 | * c-parser.c (c_parser_direct_declarator) | |
2818 | (c_parser_direct_declarator_inner): Place declarator for | |
2819 | attributes inside that for function or array, not outside. Set | |
2820 | u.id.attrs for identifiers. | |
2821 | (c_parser_parameter_declaration): Use u.id.id instead of u.id. | |
2822 | * gimple-parser.c (c_parser_gimple_declaration): Use u.id.id | |
2823 | instead of u.id. | |
2824 | ||
bdaf8be1 JJ |
2825 | 2019-11-22 Jakub Jelinek <jakub@redhat.com> |
2826 | ||
2827 | PR c/90677 | |
2828 | * c-decl.c (identifier_global_tag): Define. | |
2829 | ||
3e00ba47 RB |
2830 | 2019-11-20 Richard Biener <rguenther@suse.de> |
2831 | ||
2832 | PR c/92088 | |
2833 | * c-decl.c (grokdeclarator): Prevent inlining of nested | |
2834 | function with VLA arguments. | |
2835 | ||
8c5b727a JM |
2836 | 2019-11-20 Joseph Myers <joseph@codesourcery.com> |
2837 | ||
2838 | * c-decl.c (c_warn_type_attributes): New function. | |
2839 | (groktypename, grokdeclarator, finish_declspecs): Call | |
2840 | c_warn_type_attributes before applying attributes to types. | |
2841 | * c-tree.h (c_warn_type_attributes): Declare. | |
2842 | ||
192961ff JM |
2843 | 2019-11-19 Joseph Myers <joseph@codesourcery.com> |
2844 | ||
2845 | * c-decl.c (c_warn_unused_attributes): Use pedwarn not warning for | |
2846 | standard attributes. | |
2847 | * c-parser.c (c_parser_std_attribute): Take argument for_tm. Use | |
2848 | pedwarn for unknown standard attributes and return error_mark_node | |
2849 | for them. | |
2850 | ||
20a38017 MM |
2851 | 2019-11-18 Matthew Malcomson <matthew.malcomson@arm.com> |
2852 | ||
2853 | * c-parser.c (c_parser_parse_rtl_body): Always call | |
2854 | run_rtl_passes, even if startwith pass is not provided. | |
2855 | ||
d5fbe5e0 JM |
2856 | 2019-11-15 Joseph Myers <joseph@codesourcery.com> |
2857 | ||
2858 | * c-parser.c (c_parser_std_attribute_specifier): Diagnose | |
2859 | duplicate standard attributes. | |
2860 | ||
97cc1187 JM |
2861 | 2019-11-15 Joseph Myers <joseph@codesourcery.com> |
2862 | ||
2863 | * c-decl.c (std_attribute_table): Add maybe_unused. | |
2864 | ||
f8aea5e3 JM |
2865 | 2019-11-15 Joseph Myers <joseph@codesourcery.com> |
2866 | ||
2867 | * c-decl.c (std_attribute_table): Add fallthrough. | |
2868 | * c-parser.c (c_parser_declaration_or_fndef): Diagnose fallthrough | |
2869 | attribute at top level. | |
2870 | ||
2cc94aa8 JM |
2871 | 2019-11-15 Joseph Myers <joseph@codesourcery.com> |
2872 | ||
2873 | * c-decl.c (std_attribute_table): New. | |
2874 | (c_init_decl_processing): Register attributes from | |
2875 | std_attribute_table. | |
2876 | * c-parser.c (c_parser_attribute_arguments): Add arguments | |
2877 | require_string and allow_empty_args. All callers changed. | |
2878 | (c_parser_std_attribute): Set require_string argument for | |
2879 | "deprecated" attribute. | |
2880 | ||
7c5890cc JM |
2881 | 2019-11-14 Joseph Myers <joseph@codesourcery.com> |
2882 | ||
2883 | * c-parser.c (c_parser_postfix_expression) | |
2884 | (c_parser_check_literal_zero): Handle CPP_UTF8CHAR. | |
2885 | * gimple-parser.c (c_parser_gimple_postfix_expression): Likewise. | |
2886 | ||
e8738f4e RS |
2887 | 2019-11-14 Richard Sandiford <richard.sandiford@arm.com> |
2888 | ||
2889 | * c-typeck.c (build_conditional_expr): Use truth_type_for instead | |
2890 | of build_same_sized_truth_vector_type. | |
2891 | (build_vec_cmp): Likewise. | |
2892 | ||
b2417b59 JJ |
2893 | 2019-11-14 Jakub Jelinek <jakub@redhat.com> |
2894 | ||
bedb7f04 JJ |
2895 | * c-parser.c (c_parser_omp_context_selector): Don't require score |
2896 | argument to fit into shwi, just to be INTEGER_CST. Diagnose | |
2897 | negative score. | |
2898 | ||
b2417b59 JJ |
2899 | * c-parser.c (c_parser_omp_context_selector): Rename |
2900 | CTX_PROPERTY_IDLIST to CTX_PROPERTY_NAME_LIST, add CTX_PROPERTY_ID. | |
2901 | Use CTX_PROPERTY_ID for atomic_default_mem_order, only allow a single | |
2902 | identifier in that. For CTX_PROPERTY_NAME_LIST, allow identifiers | |
2903 | and string literals. | |
2904 | ||
4e03c3a7 JM |
2905 | 2019-11-14 Joseph Myers <joseph@codesourcery.com> |
2906 | ||
2907 | * c-tree.h (enum c_typespec_kind): Add ctsk_tagref_attrs and | |
2908 | ctsk_tagfirstref_attrs. | |
2909 | (struct c_declspecs): Update description of attrs. Add | |
2910 | postfix_attrs and non_std_attrs_seen_p. Increase size of | |
2911 | typespec_kind bit-field. | |
2912 | (c_warn_unused_attributes): New declaration. | |
2913 | (parser_xref_tag): Update prototype. | |
2914 | * c-decl.c (c_warn_unused_attributes): New function. | |
2915 | (shadow_tag_warned): Handle ctsk_tagfirstref_attrs and | |
2916 | ctsk_tagref_attrs. Handle attribute declarations. | |
2917 | (check_compound_literal_type): Handle ctsk_tagfirstref_attrs. | |
2918 | (grokdeclarator): Handle standard attributes. | |
2919 | (parser_xref_tag): Add arguments have_std_attrs and attrs. Apply | |
2920 | attributes to incomplete type reference. | |
2921 | (xref_tag): Update call to parser_xref_tag. | |
2922 | (declspecs_add_addrspace, declspecs_add_type) | |
2923 | (declspecs_add_scspec, declspecs_add_attrs): Set | |
2924 | non_std_attrs_seen_p. | |
2925 | (finish_declspecs): Apply postfix standard attributes to type. | |
2926 | * c-parser.c (c_token_starts_declspecs) | |
2927 | (c_token_starts_declaration, c_parser_next_token_starts_declspecs) | |
2928 | (c_parser_next_tokens_start_declaration): Update comments. | |
2929 | (c_parser_consume_token, c_parser_consume_pragma): Handle moving | |
2930 | parser->tokens[2] to parser->tokens[1]. | |
2931 | (c_parser_nth_token_starts_std_attributes) | |
2932 | (c_parser_std_attribute_specifier_sequence): New functions. | |
2933 | (c_parser_declaration_or_fndef): Add arguments have_attrs and | |
2934 | attrs. All callers changed. Handle standard attributes. | |
2935 | (c_parser_parms_declarator, c_parser_parms_list_declarator) | |
2936 | (c_parser_parameter_declaration): Add argument have_gnu_attrs. | |
2937 | All callers changed. | |
2938 | (c_parser_declspecs): Add arguments start_std_attr_ok and | |
2939 | end_std_attr_ok. All callers changed. Handle standard | |
2940 | attributes. | |
2941 | (c_parser_enum_specifier, c_parser_struct_or_union_specifier) | |
2942 | (c_parser_direct_declarator, c_parser_direct_declarator_inner) | |
2943 | (c_parser_compound_statement_nostart, c_parser_all_labels) | |
2944 | (c_parser_label, c_parser_statement, c_parser_for_statement): | |
2945 | Handle standard attributes. | |
2946 | * c-parser.h (c_parser_declspecs): Update prototype. | |
2947 | * gimple-parser.c (c_parser_gimple_declaration): Update call to | |
2948 | c_parser_declspecs. | |
2949 | ||
0c29cac4 ML |
2950 | 2019-11-12 Martin Liska <mliska@suse.cz> |
2951 | ||
2952 | * gimple-parser.c: Do not include params.h. | |
2953 | ||
028d4092 ML |
2954 | 2019-11-12 Martin Liska <mliska@suse.cz> |
2955 | ||
2956 | * gimple-parser.c (c_parser_parse_gimple_body): Replace old parameter syntax | |
2957 | with the new one, include opts.h if needed. Use SET_OPTION_IF_UNSET | |
2958 | macro. | |
2959 | ||
62aee289 MR |
2960 | 2019-11-12 Maciej W. Rozycki <macro@codesourcery.com> |
2961 | Frederik Harwath <frederik@codesourcery.com> | |
2962 | ||
2963 | gcc/c/ | |
2964 | * c-parser.c (OACC_SERIAL_CLAUSE_MASK): New macro. | |
2965 | (c_parser_oacc_kernels_parallel): Rename function to... | |
2966 | (c_parser_oacc_compute): ... this. Handle PRAGMA_OACC_SERIAL. | |
2967 | (c_parser_omp_construct): Update accordingly. | |
2968 | ||
2969 | ||
7cec9588 JJ |
2970 | 2019-11-11 Jakub Jelinek <jakub@redhat.com> |
2971 | ||
2972 | * c-parser.c (c_parser_translation_unit): Diagnose declare target | |
2973 | without corresponding end declare target. | |
2974 | ||
f486280c RS |
2975 | 2019-11-08 Richard Sandiford <richard.sandiford@arm.com> |
2976 | ||
2977 | * c-convert.c (convert): Only handle vector conversions if one of | |
2978 | the types satisfies gnu_vector_type_p or if -flax-vector-conversions | |
2979 | allows it. | |
2980 | * c-typeck.c (build_array_ref): Only allow vector indexing if the | |
2981 | vectors satisfy gnu_vector_type_p. | |
2982 | (build_unary_op): Only allow unary operators to be applied to | |
2983 | vectors if they satisfy gnu_vector_type_p. | |
2984 | (digest_init): Only allow by-element initialization of vectors | |
2985 | if they satisfy gnu_vector_type_p. | |
2986 | (really_start_incremental_init): Likewise. | |
2987 | (push_init_level): Likewise. | |
2988 | (pop_init_level): Likewise. | |
2989 | (process_init_element): Likewise. | |
2990 | (build_binary_op): Only allow binary operators to be applied to | |
2991 | vectors if they satisfy gnu_vector_type_p. | |
2992 | ||
017c6491 JM |
2993 | 2019-11-08 Joseph Myers <joseph@codesourcery.com> |
2994 | ||
2995 | * c-decl.c (grokparms): Convert () in a function definition to | |
2996 | (void) for C2x. | |
2997 | (store_parm_decls_oldstyle): Pedwarn for C2x. | |
2998 | (store_parm_decls): Update comment about () not generating a | |
2999 | prototype. | |
3000 | ||
c01bd174 JM |
3001 | 2019-11-07 Joseph Myers <joseph@codesourcery.com> |
3002 | ||
3003 | * c-parser.c (c_parser_attribute_arguments): New function. | |
3004 | Factored out of c_parser_gnu_attribute. | |
3005 | (c_parser_gnu_attribute): Use c_parser_attribute_arguments. | |
3006 | (c_parser_balanced_token_sequence, c_parser_std_attribute) | |
3007 | (c_parser_std_attribute_specifier): New functions. | |
3008 | (c_parser_transaction_attributes): Use | |
3009 | c_parser_std_attribute_specifier. | |
3010 | ||
471c5330 JM |
3011 | 2019-11-07 Joseph Myers <joseph@codesourcery.com> |
3012 | ||
3013 | * c-parser.c (c_parser): Remove lex_untranslated_string. Add | |
3014 | lex_joined_string and translate_strings_p. | |
3015 | (c_lex_one_token): Pass 0 or C_LEX_STRING_NO_JOIN to | |
3016 | c_lex_with_flags. | |
3017 | (c_parser_string_literal): New function. | |
3018 | (c_parser_static_assert_declaration_no_semi): Use | |
3019 | c_parser_string_literal. Do not set lex_untranslated_string. | |
3020 | (c_parser_asm_string_literal): Use c_parser_string_literal. | |
3021 | (c_parser_simple_asm_expr): Do not set lex_untranslated_string. | |
3022 | (c_parser_gnu_attributes): Set and restore translate_strings_p | |
3023 | instead of lex_untranslated_string. | |
3024 | (c_parser_asm_statement): Do not set lex_untranslated_string. | |
3025 | (c_parser_asm_operands): Likewise. | |
3026 | (c_parser_has_attribute_expression): Set and restore | |
3027 | translate_strings_p instead of lex_untranslated_string. | |
3028 | (c_parser_postfix_expression): Use c_parser_string_literal. | |
3029 | (pragma_lex): Likewise. | |
3030 | (c_parser_pragma_pch_preprocess): Set lex_joined_string. | |
3031 | (c_parse_file): Set translate_strings_p. | |
3032 | * gimple-parser.c (c_parser_gimple_postfix_expression) | |
3033 | (c_parser_gimple_or_rtl_pass_list): Use c_parser_string_literal. | |
3034 | * c-parser.c (c_parser_string_literal): Declare function. | |
3035 | ||
d0c464d2 JJ |
3036 | 2019-11-02 Jakub Jelinek <jakub@redhat.com> |
3037 | ||
3038 | * c-parser.c (c_finish_omp_declare_variant): Use | |
3039 | omp_get_context_selector instead of c_omp_get_context_selector. | |
3040 | ||
ac2cfa6c RS |
3041 | 2019-10-29 Richard Sandiford <richard.sandiford@arm.com> |
3042 | ||
3043 | * c-tree.h (c_simulate_enum_decl): Declare. | |
3044 | * c-decl.c (c_simulate_enum_decl): New function. | |
3045 | * c-objc-common.h (LANG_HOOKS_SIMULATE_ENUM_DECL): Define to the above. | |
3046 | ||
74078538 RS |
3047 | 2019-10-29 Richard Sandiford <richard.sandiford@arm.com> |
3048 | ||
3049 | * c-tree.h (c_simulate_builtin_function_decl): Declare. | |
3050 | * c-decl.c (c_simulate_builtin_function_decl): New function. | |
3051 | * c-objc-common.h (LANG_HOOKS_SIMULATE_BUILTIN_FUNCTION_DECL): Define | |
3052 | to the above. | |
3053 | ||
ad1539d5 MS |
3054 | 2019-10-28 Martin Sebor <msebor@redhat.com> |
3055 | ||
3056 | PR c/66970 | |
3057 | * c-decl.c (names_builtin_p): Define a new function. | |
3058 | ||
cb73e4e7 RB |
3059 | 2019-10-28 Richard Biener <rguenther@suse.de> |
3060 | ||
3061 | PR c/92249 | |
3062 | * gimple-parser.c (c_parser_parse_gimple_body): Make | |
3063 | current_bb the entry block initially to easier recover | |
3064 | from errors. | |
3065 | (c_parser_gimple_compound_statement): Adjust. | |
3066 | ||
135df52c JJ |
3067 | 2019-10-24 Jakub Jelinek <jakub@redhat.com> |
3068 | ||
3069 | * c-parser.c (c_finish_omp_declare_variant): Use | |
3070 | omp_context_selector_matches instead of | |
3071 | c_omp_context_selector_matches. | |
3072 | * c-decl.c (c_decl_attributes): Add "omp declare target block" | |
3073 | attribute in between declare target and end declare target | |
3074 | pragmas. | |
3075 | ||
783bfe5e JM |
3076 | 2019-10-15 Joseph Myers <joseph@codesourcery.com> |
3077 | ||
3078 | * c-parser.c (c_parser_attribute_any_word): Rename to | |
3079 | c_parser_gnu_attribute_any_word. All callers changed. | |
3080 | (c_parser_attribute): Rename to c_parser_gnu_attribute. All | |
3081 | callers changed. | |
3082 | (c_parser_attributes): Rename to c_parser_gnu_attributes. All | |
3083 | callers changed. | |
3084 | (c_parser_declaration_or_fndef, c_parser_declspecs) | |
3085 | (c_parser_enum_specifier, c_parser_struct_or_union_specifier) | |
3086 | (c_parser_struct_declaration, c_parser_declarator) | |
3087 | (c_parser_gnu_attribute, c_parser_compound_statement) | |
3088 | (c_parser_label, c_parser_statement, c_parser_objc_method_decl) | |
3089 | (c_parser_transaction_attributes): Add "gnu-" prefix to names of | |
3090 | attribute-related syntax productions. | |
3091 | ||
56898e43 RS |
3092 | 2019-10-14 Richard Sandiford <richard.sandiford@arm.com> |
3093 | ||
3094 | * c-objc-common.c (useful_aka_type_p): Replace with... | |
3095 | (get_aka_type): ...this new function. Given the original type, | |
3096 | decide which aka type to print (if any). Only look through typedefs | |
3097 | if user_facing_original_type_p. | |
3098 | (print_type): Update accordingly. | |
3099 | ||
b9424661 JJ |
3100 | 2019-10-14 Jakub Jelinek <jakub@redhat.com> |
3101 | ||
3102 | * c-parser.c (c_parser_omp_all_clauses): Change bool NESTED_P argument | |
3103 | into int NESTED, if it is 2, diagnose missing commas in between | |
3104 | clauses. | |
3105 | (c_parser_omp_context_selector): Pass 2 as last argument to | |
3106 | c_parser_omp_all_clauses. | |
3107 | ||
20de9568 JJ |
3108 | 2019-10-12 Jakub Jelinek <jakub@redhat.com> |
3109 | ||
3110 | * c-parser.c (c_parser_omp_context_selector): Improve error recovery. | |
3111 | For simd properties, put them directly into TREE_VALUE. | |
3112 | (c_finish_omp_declare_variant): Call c_omp_mark_declare_variant. | |
3113 | If c_omp_context_selector_matches is 0, don't add attribute, otherwise | |
3114 | add "omp declare variant base" attribute rather than | |
3115 | "omp declare variant". | |
3116 | ||
fe2bc27c JM |
3117 | 2019-10-11 Joseph Myers <joseph@codesourcery.com> |
3118 | ||
3119 | * c-decl.c (declspecs_add_type): Use pedwarn_c11 for DFP types. | |
3120 | ||
94e7f906 JJ |
3121 | 2019-10-10 Jakub Jelinek <jakub@redhat.com> |
3122 | ||
3123 | * c-parser.c (c_parser_omp_all_clauses): Add NESTED_P argument, if | |
3124 | true, terminate processing on closing paren and don't skip to end of | |
3125 | pragma line. | |
3126 | (c_parser_omp_declare_simd): Handle also declare variant. | |
3127 | (omp_construct_selectors, omp_device_selectors, | |
3128 | omp_implementation_selectors, omp_user_selectors): New variables. | |
3129 | (c_parser_omp_context_selector, | |
3130 | c_parser_omp_context_selector_specification, | |
3131 | c_finish_omp_declare_variant): New functions. | |
3132 | (c_finish_omp_declare_simd): Handle both declare simd and | |
3133 | declare variant. | |
3134 | (c_parser_omp_declare): Handle declare variant. | |
3135 | ||
93313b94 JM |
3136 | 2019-10-02 Joseph Myers <joseph@codesourcery.com> |
3137 | ||
3138 | * c-parser.c (c_parser_asm_statement): Handle CPP_SCOPE like two | |
3139 | CPP_COLON tokens. | |
3140 | ||
55879815 RS |
3141 | 2019-10-01 Richard Sandiford <richard.sandiford@arm.com> |
3142 | ||
3143 | * c-objc-common.c (useful_aka_type_p): New function. | |
3144 | (print_type): Use it to decide whether an aka type is worth printing. | |
3145 | ||
59bc434a JJ |
3146 | 2019-09-27 Jakub Jelinek <jakub@redhat.com> |
3147 | ||
3148 | PR c++/88203 | |
3149 | * c-parser.c (c_parser_predefined_identifier): New function. | |
3150 | (c_parser_postfix_expression): Use it. | |
3151 | (c_parser_omp_variable_list): Parse predefined identifiers. | |
3152 | * c-typeck.c (c_finish_omp_clauses): Allow predefined variables | |
3153 | in shared and firstprivate clauses, even when they are predetermined | |
3154 | shared. | |
3155 | ||
c6447c20 RS |
3156 | 2019-09-27 Richard Sandiford <richard.sandiford@arm.com> |
3157 | ||
3158 | * c-typeck.c (build_function_call_vec): Take the original function | |
3159 | decl as an optional final parameter. Pass all built-in calls to | |
3160 | check_builtin_function_arguments. | |
3161 | ||
522da4c2 EB |
3162 | 2019-09-20 Eric Botcazou <ebotcazou@adacore.com> |
3163 | ||
3164 | PR c/91815 | |
3165 | * c-decl.c (pushdecl): In C detect duplicate declarations across scopes | |
3166 | of identifiers in the external scope only for variables and functions. | |
3167 | ||
68e2c199 PK |
3168 | 2019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
3169 | ||
3170 | PR c/78736 | |
3171 | * c-typeck.c (convert_for_assignment): Handle Wenum-conversion. | |
3172 | ||
22f8849d IS |
3173 | 2019-08-23 Iain Sandoe <iain@sandoe.co.uk> |
3174 | ||
3175 | PR pch/61250 | |
3176 | * c-parser.c (c_parse_file): Call c_common_no_more_pch () | |
3177 | after determining that the first token is not | |
3178 | PRAGMA_GCC_PCH_PREPROCESS. | |
3179 | ||
db376f45 EB |
3180 | 2019-08-22 Eric Botcazou <ebotcazou@adacore.com> |
3181 | ||
3182 | * c-parser.c (c_parser_declaration_or_fndef): Set DECL_ARGUMENTS of a | |
3183 | FUNCTION_DECL to the right value in the presence of nested declarators. | |
3184 | ||
4d732405 RS |
3185 | 2019-08-13 Richard Sandiford <richard.sandiford@arm.com> |
3186 | ||
3187 | PR middle-end/91421 | |
3188 | * c-decl.c (merge_decls): Use copy_decl_built_in_function. | |
3189 | ||
cb1180d5 RS |
3190 | 2019-08-13 Richard Sandiford <richard.sandiford@arm.com> |
3191 | ||
3192 | PR middle-end/91421 | |
3193 | * c-decl.c (header_for_builtin_fn): Take a FUNCTION_DECL instead | |
3194 | of a built_in_function. | |
3195 | (diagnose_mismatched_decls, implicitly_declare): Update accordingly. | |
3196 | ||
77eb117f JJ |
3197 | 2019-08-10 Jakub Jelinek <jakub@redhat.com> |
3198 | ||
3199 | * c-parser.c (c_parser_omp_clause_name): Parse device_type. | |
3200 | (c_parser_omp_clause_device_type): New function. | |
3201 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_DEVICE_TYPE. | |
3202 | (OMP_DECLARE_TARGET_CLAUSE_MASK): Add PRAGMA_OMP_CLAUSE_DEVICE_TYPE. | |
3203 | (c_parser_omp_declare_target): Handle device_type clauses. Remove | |
3204 | diagnostics for declare target with clauses nested in clause-less | |
3205 | declare target declaration-definition-seq. | |
3206 | * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_DEVICE_TYPE. | |
3207 | ||
2c3b8bad JJ |
3208 | 2019-08-09 Jakub Jelinek <jakub@redhat.com> |
3209 | ||
bb522e2e JJ |
3210 | * c-parser.c (check_no_duplicate_clause): Simplify using |
3211 | omp_find_clause. | |
3212 | (c_parser_omp_clause_if): Fix up printing of target {enter,exit} data | |
3213 | directive name modifiers. | |
3214 | (c_parser_omp_clause_proc_bind): Check for duplicate proc_bind clause. | |
3215 | ||
2c3b8bad JJ |
3216 | PR c/91401 |
3217 | * c-parser.c (c_parser_omp_clause_dist_schedule): Fix up typos in the | |
3218 | check_no_duplicate_clause call. Comment it out, instead emit a | |
3219 | warning for duplicate dist_schedule clauses. | |
3220 | ||
99769e7f RS |
3221 | 2019-08-08 Richard Sandiford <richard.sandiford@arm.com> |
3222 | ||
3223 | * c-decl.c (finish_enum): Clear C_TYPE_BEING_DEFINED. | |
3224 | ||
8860d270 JJ |
3225 | 2019-08-08 Jakub Jelinek <jakub@redhat.com> |
3226 | ||
3227 | * c-typeck.c (c_finish_omp_clauses): For C_ORT_OMP | |
3228 | OMP_CLAUSE_USE_DEVICE_* clauses use oacc_reduction_head bitmap | |
3229 | instead of generic_head to track duplicates. | |
3230 | ||
398e3feb JJ |
3231 | 2019-08-07 Jakub Jelinek <jakub@redhat.com> |
3232 | ||
3233 | * c-parser.c (c_parser_omp_clause_name): Parse use_device_addr clause. | |
3234 | (c_parser_omp_clause_use_device_addr): New function. | |
3235 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. | |
3236 | (OMP_TARGET_DATA_CLAUSE_MASK): Add PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. | |
3237 | (c_parser_omp_target_data): Handle PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR | |
3238 | like PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR, adjust diagnostics about no | |
3239 | map or use_device_* clauses. | |
3240 | * c-typeck.c (c_finish_omp_clauses): For OMP_CLAUSE_USE_DEVICE_PTR | |
3241 | in OpenMP, require pointer type rather than pointer or array type. | |
3242 | Handle OMP_CLAUSE_USE_DEVICE_ADDR. | |
3243 | ||
a28351e7 JJ |
3244 | 2019-07-31 Jakub Jelinek <jakub@redhat.com> |
3245 | ||
3246 | PR c/91192 | |
3247 | * c-parser.c (c_parser_sizeof_expression): Call set_c_expr_source_range | |
3248 | even if finish is UNKNOWN_LOCATION, just use start as finish in that | |
3249 | case. | |
3250 | ||
6343b6bf ML |
3251 | 2019-07-25 Martin Liska <mliska@suse.cz> |
3252 | Dominik Infuhr <dominik.infuehr@theobroma-systems.com> | |
3253 | ||
3254 | PR c++/23383 | |
3255 | * c-decl.c (merge_decls): Merge OPERATOR_DELETE flag. | |
3256 | ||
cb50701e ML |
3257 | 2019-07-25 Martin Liska <mliska@suse.cz> |
3258 | ||
3259 | * c-decl.c (merge_decls): Use new macros | |
3260 | (e.g. DECL_SET_LAMBDA_FUNCTION and DECL_LAMBDA_FUNCTION_P). | |
3261 | ||
62e3e66f RB |
3262 | 2019-07-23 Richard Biener <rguenther@suse.de> |
3263 | ||
3264 | PR tree-optimization/83518 | |
3265 | * gimple-parser.c (c_parser_parse_gimple_body): When we have | |
3266 | a CFG also rebuild cgraph edges. | |
3267 | ||
554a530f JJ |
3268 | 2019-07-20 Jakub Jelinek <jakub@redhat.com> |
3269 | ||
3270 | * c-parser.c (c_parser_omp_clause_name): Handle bind clause. | |
3271 | (c_parser_omp_clause_bind): New function. | |
3272 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_BIND. | |
3273 | (OMP_LOOP_CLAUSE_MASK): Define. | |
3274 | (c_parser_omp_loop): New function. | |
3275 | (c_parser_omp_parallel, c_parser_omp_teams): Handle parsing of | |
3276 | loop combined with parallel or teams. | |
3277 | (c_parser_omp_construct): Handle PRAGMA_OMP_LOOP. | |
3278 | * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_BIND. | |
3279 | ||
d119bf79 RS |
3280 | 2019-07-18 Richard Sandiford <richard.sandiford@arm.com> |
3281 | ||
3282 | PR c/53633 | |
3283 | * c-decl.c (finish_function): Check targetm.warn_func_return | |
3284 | before issuing a -Wreturn-type warning. | |
3285 | ||
ab20d992 | 3286 | 2019-07-12 Alexandre Oliva <oliva@adacore.com> |
fdc1f343 AO |
3287 | |
3288 | * gimple-parser.c (c_parser_gimple_try_stmt): New. | |
3289 | (c_parser_compound_statement): Call it. | |
3290 | ||
1fdd6f04 JJ |
3291 | 2019-07-12 Jakub Jelinek <jakub@redhat.com> |
3292 | ||
3293 | * c-parser.c (c_parser_omp_clause_name): Handle order clause. | |
3294 | (c_parser_omp_clause_order): New function. | |
3295 | (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_ORDER. | |
3296 | (OMP_SIMD_CLAUSE_MASK, OMP_FOR_CLAUSE_MASK): Add | |
3297 | PRAGMA_OMP_CLAUSE_ORDER. | |
3298 | * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_ORDER. | |
3299 | ||
8389386c RB |
3300 | 2019-07-10 Richard Biener <rguenther@suse.de> |
3301 | ||
3302 | * gimple-parser.c (c_parser_gimple_postfix_expression): Support | |
3303 | _Literal (int *) &x for address literals. | |
3304 | ||
99b1c316 MS |
3305 | 2019-07-09 Martin Sebor <msebor@redhat.com> |
3306 | ||
3307 | PR c++/61339 | |
3308 | * c-decl.c (xref_tag): Change class-key of PODs to struct and others | |
3309 | to class. | |
3310 | (field_decl_cmp): Same. | |
3311 | * c-parser.c (c_parser_struct_or_union_specifier): Same. | |
3312 | * c-tree.h: Same. | |
3313 | * gimple-parser.c (c_parser_gimple_compound_statement): Same. | |
3314 | ||
6c1dae73 MS |
3315 | 2019-07-09 Martin Sebor <msebor@redhat.com> |
3316 | ||
3317 | PR c++/61339 | |
3318 | * c-decl.c: Change class-key from class to struct and vice versa | |
3319 | to match convention and avoid -Wclass-is-pod and -Wstruct-no-pod. | |
3320 | * gimple-parser.c: Same. | |
3321 | ||
69b5279e RB |
3322 | 2019-07-01 Richard Biener <rguenther@suse.de> |
3323 | ||
3324 | * gimple-parser.c (c_parser_gimple_postfix_expression): Handle | |
3325 | _Literal (char *) &"foo" for address literals pointing to | |
3326 | STRING_CSTs. | |
3327 | ||
ab20d992 JJ |
3328 | 2019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com> |
3329 | ||
3330 | * c-parser.c (c_parse_init): Create keyword for "__intN__" type. | |
3331 | * c-decl.c (declspecs_add_type): Don't pedwarn about "__intN" ISO | |
3332 | C incompatibility if alternate "__intN__" form is used. | |
3333 | ||
1e3d475e MS |
3334 | 2019-06-24 Martin Sebor <msebor@redhat.com> |
3335 | ||
3336 | * c-typeck.c (build_binary_op): Hyphenate floating-point. | |
3337 | ||
bf38f7e9 JJ |
3338 | 2019-06-10 Jakub Jelinek <jakub@redhat.com> |
3339 | ||
3340 | * c-parser.c (c_parser_pragma): Reject PRAGMA_OMP_SCAN. | |
3341 | (c_parser_omp_clause_reduction): Don't sorry_at on inscan reductions. | |
3342 | (c_parser_omp_scan_loop_body): New function. | |
3343 | (c_parser_omp_for_loop): Call c_parser_omp_scan_loop_body if there are | |
3344 | inscan reduction clauses. | |
3345 | * c-typeck.c (c_finish_omp_clauses): Reject mixing inscan with | |
3346 | non-inscan reductions on the same construct, or inscan reductions with | |
3347 | ordered or schedule clauses, or inscan array reductions. | |
3348 | ||
65985d78 MS |
3349 | 2019-06-05 Martin Sebor <msebor@redhat.com> |
3350 | ||
3351 | PR c/90737 | |
3352 | * c-typeck.c (c_finish_return): Only consider functions returning | |
3353 | pointers as candidates for -Wreturn-local-addr. | |
3354 | ||
0ecf545c MS |
3355 | 2019-06-05 Martin Sebor <msebor@redhat.com> |
3356 | ||
3357 | * c-decl.c (start_decl): Adjust quoting and hyphenation | |
3358 | in diagnostics. | |
3359 | (finish_decl): Same. | |
3360 | (finish_enum): Same. | |
3361 | (start_function): Same. | |
3362 | (declspecs_add_type): Same. | |
3363 | * c-parser.c (warn_for_abs): Same. | |
3364 | * c-typeck.c (build_binary_op): Same. | |
3365 | ||
e03436e7 TS |
3366 | 2019-05-17 Thomas Schwinge <thomas@codesourcery.com> |
3367 | ||
b48f44bf TS |
3368 | PR c/89433 |
3369 | * c-parser.c (c_finish_oacc_routine): Rework checking if already | |
3370 | marked with an OpenACC 'routine' directive. | |
3371 | ||
5bf04509 TS |
3372 | PR c/89433 |
3373 | * c-parser.c (c_parser_oacc_routine): Normalize order of clauses. | |
3374 | (c_finish_oacc_routine): Call oacc_verify_routine_clauses. | |
3375 | ||
e03436e7 TS |
3376 | PR c/89433 |
3377 | * c-parser.c (c_finish_oacc_routine): Refer to OpenACC 'routine' | |
3378 | clauses from "omp declare target" attribute. | |
3379 | ||
a9c697b8 MS |
3380 | 2019-05-16 Martin Sebor <msebor@redhat.com> |
3381 | ||
ab20d992 JJ |
3382 | * c-decl.c (start_decl): Quote keywords, operators, and |
3383 | types in diagnostics. | |
3384 | (finish_decl): Same. | |
3385 | * c-parser.c (c_parser_asm_statement): Same. | |
3386 | (c_parser_conditional_expression): Same. | |
3387 | (c_parser_transaction_cancel): Same. | |
3388 | * c-typeck.c (c_common_type): Same. | |
3389 | (build_conditional_expr): Same. | |
3390 | (digest_init): Same. | |
3391 | (process_init_element): Same. | |
3392 | (build_binary_op): Same. | |
a9c697b8 | 3393 | |
c4499192 RB |
3394 | 2019-05-17 Richard Biener <rguenther@suse.de> |
3395 | ||
3396 | * gimple-parser.c (c_parser_gimple_statement): Handle __VEC_PERM. | |
3397 | (c_parser_gimple_unary_expression): Likewise. | |
3398 | (c_parser_gimple_parentized_ternary_expression): New function. | |
3399 | ||
adfe6e4b RB |
3400 | 2019-05-16 Richard Biener <rguenther@suse.de> |
3401 | ||
3402 | * gimple-parser.c (c_parser_gimple_statement): Handle __BIT_INSERT. | |
3403 | (c_parser_gimple_unary_expression): Likewise. | |
3404 | ||
186dabf2 RB |
3405 | 2019-05-15 Richard Biener <rguenther@suse.de> |
3406 | ||
3407 | * gimple-parser.c (c_parser_gimple_postfix_expression): Handle | |
3408 | __BIT_FIELD_REF. | |
3409 | ||
1158c5b4 RB |
3410 | 2019-05-14 Richard Biener <rguenther@suse.de> |
3411 | ||
3412 | * gimple-parser.c (c_parser_gimple_statement): Remove | |
3413 | questionable auto-promotion to VIEW_CONVERT_EXPR. | |
3414 | (c_parser_gimple_typespec): Split out from __MEM parsing. | |
3415 | (c_parser_gimple_postfix_expression): Handle __VIEW_CONVERT. | |
3416 | * tree-pretty-print.c (dump_generic_node): Dump VIEW_CONVERT_EXPR | |
3417 | as __VIEW_CONVERT with -gimple. | |
3418 | ||
fd4485aa ML |
3419 | 2019-05-09 Martin Liska <mliska@suse.cz> |
3420 | ||
3421 | * gimple-parser.c (c_parser_gimple_statement): Support __MIN and | |
3422 | __MAX. | |
3423 | (c_parser_gimple_unary_expression): Parse also binary expression | |
3424 | __MIN and __MAX. | |
3425 | (c_parser_gimple_parentized_binary_expression): New function. | |
3426 | ||
d276406a ML |
3427 | 2019-05-09 Martin Liska <mliska@suse.cz> |
3428 | ||
3429 | * gimple-parser.c (struct gimple_parser): Add probability. | |
3430 | for gimple_parser_edge. | |
3431 | (gimple_parser::push_edge): Add new argument probability. | |
3432 | (c_parser_gimple_parse_bb_spec): Parse also probability | |
3433 | if present. | |
3434 | (c_parser_parse_gimple_body): Set edge probability. | |
3435 | (c_parser_gimple_compound_statement): Consume token | |
3436 | before calling c_parser_gimple_goto_stmt. | |
3437 | Parse BB counts. | |
3438 | (c_parser_gimple_statement): Pass new argument. | |
3439 | (c_parser_gimple_goto_stmt): Likewise. | |
3440 | (c_parser_gimple_if_stmt): Likewise. | |
3441 | (c_parser_gimple_or_rtl_pass_list): Parse hot_bb_threshold. | |
3442 | * c-parser.c (c_parser_declaration_or_fndef): Pass | |
3443 | hot_bb_threshold argument. | |
3444 | * c-tree.h (struct c_declspecs): Add hot_bb_threshold | |
3445 | field. | |
3446 | (c_parser_gimple_parse_bb_spec_edge_probability): New. | |
3447 | ||
f179b64e JJ |
3448 | 2019-04-26 Jakub Jelinek <jakub@redhat.com> |
3449 | ||
3450 | PR debug/90197 | |
3451 | * c-tree.h (c_finish_loop): Add 2 further location_t arguments. | |
3452 | * c-parser.c (c_parser_while_statement): Adjust c_finish_loop caller. | |
3453 | (c_parser_do_statement): Likewise. | |
3454 | (c_parser_for_statement): Likewise. Formatting fixes. | |
3455 | * c-typeck.c (c_finish_loop): Add COND_LOCUS and INCR_LOCUS arguments, | |
3456 | emit DEBUG_BEGIN_STMTs if needed. | |
3457 | ||
e7178413 JJ |
3458 | 2019-04-19 Jakub Jelinek <jakub@redhat.com> |
3459 | ||
c280b7ee JJ |
3460 | PR c/89888 |
3461 | * c-typeck.c (struct c_switch): Remove outside_range_p member. | |
3462 | (c_start_case): Don't clear it. | |
3463 | (do_case): Adjust c_add_case_label caller. | |
3464 | (c_finish_case): Adjust c_do_switch_warnings caller. | |
3465 | ||
e7178413 JJ |
3466 | PR c++/90108 |
3467 | * c-decl.c (merge_decls): If remove is main variant and | |
3468 | DECL_ORIGINAL_TYPE is some other type, remove a DECL_ORIGINAL_TYPE | |
3469 | variant that has newdecl as TYPE_NAME if any. | |
3470 | ||
60a2c645 JJ |
3471 | 2019-04-12 Jakub Jelinek <jakub@redhat.com> |
3472 | ||
3473 | PR c/89933 | |
3474 | * c-decl.c (merge_decls): When newdecl's type is its main variant, | |
3475 | don't try to remove it from the variant list, but instead assert | |
3476 | it has no variants. | |
3477 | ||
2a82beaa RB |
3478 | 2019-04-01 Richard Biener <rguenther@suse.de> |
3479 | ||
3480 | PR c/71598 | |
3481 | * c-tree.h (c_get_alias_set): Declare. | |
3482 | * c-objc-common.h (LANG_HOOKS_GET_ALIAS_SET): Use c_get_alias_set. | |
3483 | * c-objc-common.c (c_get_alias_set): Treat enumeral types | |
3484 | as the underlying integer type. | |
3485 | ||
bec1da64 MS |
3486 | 2019-03-19 Martin Sebor <msebor@redhat.com> |
3487 | ||
3488 | PR tree-optimization/89688 | |
3489 | * c-decl.c (finish_decl): Call braced_lists_to_string for more | |
3490 | kinds of initializers. | |
3491 | ||
855cd9b1 JJ |
3492 | 2019-03-19 Jakub Jelinek <jakub@redhat.com> |
3493 | ||
3494 | PR c/89734 | |
3495 | * c-decl.c (grokdeclarator): Call c_build_qualified_type on function | |
3496 | return type even if quals_used is 0. Formatting fixes. | |
3497 | ||
baa09dc5 RB |
3498 | 2019-03-14 Richard Biener <rguenther@suse.de> |
3499 | ||
3500 | * c-tree.h (enum c_declspec_il): New. | |
3501 | (struct c_declspecs): Merge gimple_p and rtl_p into declspec_il | |
3502 | enum bitfield. | |
3503 | * c-parser.c (c_parser_declaration_or_fndef): Adjust accordingly. | |
3504 | Pass start pass and declspec_il to c_parser_parse_gimple_body. | |
3505 | (c_parser_declspecs): Adjust. | |
3506 | * gimple-parser.c: Include cfg.h, cfghooks.h, cfganal.h, tree-cfg.h, | |
3507 | gimple-iterator.h, cfgloop.h, tree-phinodes.h, tree-into-ssa.h | |
3508 | and bitmap.h. | |
3509 | (struct gimple_parser): New. | |
3510 | (gimple_parser::push_edge): New method. | |
3511 | (c_parser_gimple_parse_bb_spec): New helper. | |
3512 | (c_parser_parse_gimple_body): Get start pass and IL specification. | |
3513 | Initialize SSA and CFG. | |
3514 | (c_parser_gimple_compound_statement): Handle CFG and SSA build. | |
3515 | Build a gimple_parser parsing state and pass it along. | |
3516 | (c_parser_gimple_statement): Change intermittend __PHI internal | |
3517 | function argument for the edge. | |
3518 | (c_parser_gimple_or_rtl_pass_list): Handle ssa, cfg flags. | |
3519 | (c_parser_gimple_goto_stmt): Record edges to build. | |
3520 | (c_parser_gimple_if_stmt): Likewise. | |
3521 | * gimple-parser.h (c_parser_parse_gimple_body): Adjust. | |
3522 | (c_parser_gimple_or_rtl_pass_list): Likewise. | |
3523 | ||
a3f9f006 ML |
3524 | 2019-03-11 Martin Liska <mliska@suse.cz> |
3525 | ||
3526 | * c-decl.c (check_for_loop_decls): Wrap an option name | |
3527 | in a string format message and fix GNU coding style. | |
3528 | * c-parser.c (c_parser_declspecs): Likewise. | |
3529 | ||
1db01ff9 JJ |
3530 | 2019-03-08 Jakub Jelinek <jakub@redhat.com> |
3531 | ||
3532 | PR tree-optimization/89550 | |
3533 | * c-decl.c (finish_function): Only set TREE_NO_WARNING if warning_at | |
3534 | returned true. | |
3535 | (c_write_global_declarations_1): Only set TREE_NO_WARNING if pedwarn | |
3536 | or warning returned true. | |
3537 | ||
66dcb747 JJ |
3538 | 2019-02-28 Jakub Jelinek <jakub@redhat.com> |
3539 | ||
3540 | PR c/89525 | |
3541 | * c-typeck.c (convert_arguments): Call inform_declaration only if | |
3542 | the previous warning_at call returned true. | |
3543 | ||
2263c9f2 TS |
3544 | 2019-02-22 Thomas Schwinge <thomas@codesourcery.com> |
3545 | ||
3546 | * c-parser.c (c_parser_oacc_shape_clause): Add loc formal | |
3547 | parameter. Adjust all users. | |
3548 | (c_parser_oacc_simple_clause): Replace parser with loc formal | |
3549 | parameter. Adjust all users. | |
3550 | ||
ab20d992 | 3551 | 2019-02-19 Chung-Lin Tang <cltang@codesourcery.com> |
19695f4d CLT |
3552 | |
3553 | PR c/87924 | |
3554 | * c-parser.c (c_parser_oacc_clause_wait): Add representation of wait | |
3555 | clause without argument as 'wait (GOMP_ASYNC_NOVAL)', adjust comments. | |
3556 | ||
5f88ba10 JJ |
3557 | 2019-02-15 Jakub Jelinek <jakub@redhat.com> |
3558 | ||
3559 | PR c/89340 | |
3560 | * c-decl.c (start_function): Clear TREE_PUBLIC on nested functions | |
3561 | before c_decl_attributes rather than after it. | |
3562 | ||
cfc30fd1 JJ |
3563 | 2019-02-06 Jakub Jelinek <jakub@redhat.com> |
3564 | ||
3565 | PR c/89211 | |
3566 | * c-parser.c (c_parser_declaration_or_fndef): Don't update | |
3567 | DECL_ARGUMENTS of d if it has been defined already. Use a single if | |
3568 | instead of 3 nested ifs. | |
3569 | ||
fbe83e6b JM |
3570 | 2019-02-06 Joseph Myers <joseph@codesourcery.com> |
3571 | ||
3572 | PR c/88584 | |
3573 | * c-decl.c (finish_decl): Do not complete array types for arrays | |
3574 | with external linkage not at file scope. | |
3575 | ||
f461f938 RB |
3576 | 2019-02-05 Richard Biener <rguenther@suse.de> |
3577 | ||
3578 | PR c/88606 | |
3579 | * c-decl.c (finish_struct): Reset TYPE_TRANSPARENT_AGGR on | |
3580 | all type variants when not supported. | |
3581 | ||
fe509359 JJ |
3582 | 2019-01-30 Jakub Jelinek <jakub@redhat.com> |
3583 | ||
3584 | PR c/89061 | |
3585 | * c-tree.h (C_DECL_COMPOUND_LITERAL_P): Define. | |
3586 | * c-decl.c (decl_jump_unsafe): Return false for | |
3587 | C_DECL_COMPOUND_LITERAL_P decls. | |
3588 | (build_compound_literal): Set C_DECL_COMPOUND_LITERAL_P. | |
3589 | ||
6a335b96 JJ |
3590 | 2019-01-29 Jakub Jelinek <jakub@redhat.com> |
3591 | ||
f4b7e754 JJ |
3592 | PR c/89045 |
3593 | * c-decl.c (build_compound_literal): Don't pushdecl if in parameter | |
3594 | scope. | |
3595 | ||
6a335b96 JJ |
3596 | PR c/86125 |
3597 | * c-decl.c (last_fileptr_type): Remove. | |
3598 | (last_structptr_types): New variable. | |
3599 | (match_builtin_function_types): Compare TYPE_MAIN_VARIANT of | |
3600 | {old,new}rettype instead of the types themselves. Assert | |
3601 | last_structptr_types array has the same number of elements | |
3602 | as builtin_structptr_types array. Use TYPE_MAIN_VARIANT for | |
3603 | argument oldtype and newtype. Instead of handling | |
3604 | just fileptr_type_node specially, handle all builtin_structptr_types | |
3605 | pointer nodes. Formatting fix. | |
3606 | ||
d8b5a1a0 MS |
3607 | 2019-01-24 Martin Sebor <msebor@redhat.com> |
3608 | ||
3609 | PR c/86125 | |
3610 | PR c/88886 | |
3611 | PR middle-end/86308 | |
3612 | * c-decl.c (match_builtin_function_types): Add arguments. | |
3613 | (diagnose_mismatched_decls): Diagnose mismatched declarations | |
3614 | of built-ins more strictly. | |
3615 | ||
e21c4491 JJ |
3616 | 2019-01-24 Jakub Jelinek <jakub@redhat.com> |
3617 | ||
3618 | PR c++/88976 | |
3619 | * c-typeck.c (c_finish_omp_cancel): Diagnose more than one if | |
3620 | on #pragma omp cancel with different modifiers. | |
3621 | ||
420183d9 L |
3622 | 2019-01-18 H.J. Lu <hongjiu.lu@intel.com> |
3623 | ||
3624 | PR c/51628 | |
3625 | PR c/88664 | |
3626 | * c-typeck.c (convert_for_assignment): Upate the | |
3627 | warn_for_address_or_pointer_of_packed_member call. | |
3628 | ||
17ad43dd TH |
3629 | 2019-01-16 Tom Honermann <tom@honermann.net> |
3630 | Jason Merrill <jason@redhat.com> | |
3631 | ||
3632 | * c-typeck.c (digest_init): Revised the error message produced for | |
3633 | ill-formed cases of array initialization with a string literal. | |
3634 | (error_init): Make variadic. | |
3635 | ||
5f07d78a JJ |
3636 | 2019-01-12 Jakub Jelinek <jakub@redhat.com> |
3637 | ||
3638 | * c-typeck.c (convert_for_assignment): Fix a comment typo. | |
3639 | ||
c4581bbf JJ |
3640 | 2019-01-07 Jakub Jelinek <jakub@redhat.com> |
3641 | ||
3642 | PR c/88701 | |
3643 | * c-decl.c (build_compound_literal): If not TREE_STATIC, only pushdecl | |
3644 | if current_function_decl is non-NULL. | |
3645 | ||
65c5b1eb JM |
3646 | 2019-01-07 Joseph Myers <joseph@codesourcery.com> |
3647 | ||
3648 | PR c/88720 | |
3649 | PR c/88726 | |
3650 | * c-decl.c (pop_scope): Use TREE_PUBLIC and b->nested to determine | |
3651 | whether a function is nested, not DECL_EXTERNAL. Diagnose inline | |
3652 | functions declared but never defined only for external scope, not | |
3653 | for other scopes. | |
3654 | ||
d8fcab68 JJ |
3655 | 2019-01-07 Jakub Jelinek <jakub@redhat.com> |
3656 | ||
3657 | PR c++/85052 | |
3658 | * c-parser.c (c_parser_postfix_expression): Parse | |
3659 | __builtin_convertvector. | |
3660 | ||
a5544970 JJ |
3661 | 2019-01-01 Jakub Jelinek <jakub@redhat.com> |
3662 | ||
3663 | Update copyright years. | |
3664 | ||
da77eace L |
3665 | 2018-12-20 H.J. Lu <hongjiu.lu@intel.com> |
3666 | ||
3667 | PR c/51628 | |
3668 | * c-typeck.c (convert_for_assignment): Call | |
3669 | warn_for_address_or_pointer_of_packed_member. | |
3670 | ||
1edf8866 SB |
3671 | 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org> |
3672 | ||
3673 | * c-parser.c (c_parser_asm_statement) <RID_CONST, RID_RESTRICT>: Give | |
3674 | a more specific error message (instead of just falling through). | |
3675 | ||
db4fd626 SB |
3676 | 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org> |
3677 | ||
3678 | * c-parser.c (c_parser_asm_statement): Keep track of the location each | |
3679 | asm qualifier is first seen; use that to give nicer "duplicate asm | |
3680 | qualifier" messages. Delete 'quals" variable, instead pass the | |
3681 | "is_volatile_ flag to build_asm_stmt directly. | |
3682 | * c-tree.h (build_asm_stmt): Make the first arg bool instead of tree. | |
3683 | * c-typeck.c (build_asm_stmt): Ditto; adjust. | |
3684 | ||
9c9cfcbb SB |
3685 | 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org> |
3686 | ||
3687 | * c-parser.c (c_parser_asm_statement): Rewrite the loop to work without | |
3688 | "done" boolean variable. | |
3689 | ||
a14feb3c DM |
3690 | 2018-12-19 David Malcolm <dmalcolm@redhat.com> |
3691 | ||
3692 | PR c++/87504 | |
3693 | * c-typeck.c (class maybe_range_label_for_tree_type_mismatch): | |
3694 | Move from here to gcc-rich-location.h and gcc-rich-location.c. | |
3695 | (build_binary_op): Use struct op_location_t and | |
3696 | class binary_op_rich_location. | |
3697 | ||
6d939173 JJ |
3698 | 2018-12-11 Jakub Jelinek <jakub@redhat.com> |
3699 | ||
3700 | PR sanitizer/88426 | |
3701 | * c-convert.c (convert): Call c_fully_fold before calling | |
3702 | ubsan_instrument_float_cast. | |
3703 | ||
b7055028 SB |
3704 | 2018-12-08 Segher Boessenkool <segher@kernel.crashing.org> |
3705 | ||
3706 | * c-parser (c_parser_asm_statement) [RID_INLINE]: Delete stray line | |
3707 | setting "quals". | |
3708 | ||
5b76e75f SB |
3709 | 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org> |
3710 | ||
3711 | * c-parser.c (c_parser_asm_statement): Detect the inline keyword | |
3712 | after asm. Pass a flag for it to build_asm_expr. | |
3713 | * c-tree.h (build_asm_expr): Update declaration. | |
3714 | * c-typeck.c (build_asm_stmt): Add is_inline parameter. Use it to | |
3715 | set ASM_INLINE_P. | |
3716 | ||
30bd42b9 SB |
3717 | 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org> |
3718 | ||
3719 | PR inline-asm/55681 | |
3720 | * c-parser.c (c_parser_asm_statement): Update grammar. Allow any | |
3721 | combination of volatile and goto, in any order, without repetitions. | |
3722 | ||
9df6c0e4 JB |
3723 | 2018-12-04 James Norris <jnorris@codesourcery.com> |
3724 | Cesar Philippidis <cesar@codesourcery.com> | |
3725 | Julian Brown <julian@codesourcery.com> | |
3726 | ||
3727 | * c-parser.c (c_parser_oacc_wait_list): Remove dead diagnostic | |
3728 | code. | |
3729 | ||
f44697b7 RB |
3730 | 2018-11-30 Richard Biener <rguenther@suse.de> |
3731 | ||
3732 | * gimple-parser.c (c_parser_gimple_postfix_expression): Parse | |
3733 | _Literal (type) { ... } as empty aggregate or vector constructor. | |
3734 | ||
550dfbdc MS |
3735 | 2018-11-29 Martin Sebor <msebor@redhat.com> |
3736 | ||
3737 | PR c/88091 | |
3738 | * c-typeck.c (convert_argument): Add a parameter. Adjust indentation. | |
3739 | (convert_arguments): Add comments. Pass additional argument to | |
3740 | the function above. | |
3741 | ||
673670da MS |
3742 | 2018-11-29 Martin Sebor <msebor@redhat.com> |
3743 | ||
3744 | PR c/88172 | |
3745 | PR testsuite/88208 | |
3746 | * c-decl.c (declspec_add_alignas): Adjust call to check_user_alignment. | |
3747 | ||
db1d09b0 MS |
3748 | 2018-11-23 Martin Sebor <msebor@redhat.com> |
3749 | ||
3750 | PR testsuite/88098 | |
3751 | * c-typeck.c (convert_arguments): Call builtin_decl_explicit instead. | |
3752 | (maybe_warn_builtin_no_proto_arg): Handle short enum to int promotion. | |
3753 | ||
98f08eb8 MS |
3754 | 2018-11-20 Martin Sebor <msebor@redhat.com> |
3755 | ||
3756 | * c-parser.c (c_parser_has_attribute_expression): New function. | |
3757 | (c_parser_attribute): New function. | |
3758 | (c_parser_attributes): Move code into c_parser_attribute. | |
3759 | (c_parser_unary_expression): Handle RID_HAS_ATTRIBUTE_EXPRESSION. | |
3760 | ||
cd5da983 MS |
3761 | 2018-11-15 Martin Sebor <msebor@redhat.com> |
3762 | ||
3763 | PR c/83656 | |
3764 | * c-decl.c (header_for_builtin_fn): Declare. | |
3765 | (diagnose_mismatched_decls): Diagnose declarations of built-in | |
3766 | functions without a prototype. | |
3767 | * c-typeck.c (maybe_warn_builtin_no_proto_arg): New function. | |
3768 | (convert_argument): Same. | |
3769 | (convert_arguments): Factor code out into convert_argument. | |
3770 | Detect mismatches between built-in formal arguments in calls | |
3771 | to built-in without prototype. | |
3772 | (build_conditional_expr): Same. | |
3773 | (type_or_builtin_type): New function. | |
3774 | (convert_for_assignment): Add argument. Conditionally issue | |
3775 | warnings instead of errors for mismatches. | |
3776 | ||
620e594b DM |
3777 | 2018-11-13 David Malcolm <dmalcolm@redhat.com> |
3778 | ||
3779 | * c-decl.c: Replace "source_location" with "location_t". | |
3780 | * c-tree.h: Likewise. | |
3781 | * c-typeck.c: Likewise. | |
3782 | * gimple-parser.c: Likewise. | |
3783 | ||
3179ebae JJ |
3784 | 2018-11-09 Jakub Jelinek <jakub@redhat.com> |
3785 | ||
81a227c6 JJ |
3786 | * c-parser.c (c_parser_omp_clause_final): Use |
3787 | c_parser_expr_no_commas, convert_lvalue_to_rvalue, | |
3788 | c_objc_common_truthvalue_conversion, c_fully_fold and parentheses | |
3789 | parsing instead of c_parser_paren_condition. | |
3790 | (c_parser_omp_clause_if): Use c_parser_expr_no_commas, | |
3791 | convert_lvalue_to_rvalue, c_objc_common_truthvalue_conversion and | |
3792 | c_fully_fold instead of c_parser_condition. | |
3793 | (c_parser_omp_clause_num_threads, c_parser_omp_clause_num_tasks, | |
3794 | c_parser_omp_clause_grainsize, c_parser_omp_clause_priority, | |
3795 | c_parser_omp_clause_hint, c_parser_omp_clause_num_teams, | |
3796 | c_parser_omp_clause_thread_limit, c_parser_omp_clause_linear): Use | |
3797 | c_parser_expr_no_commas instead of c_parser_expression. | |
3798 | ||
98c91c56 JJ |
3799 | * c-parser.c (c_parser_omp_clause_reduction): Call sorry_at on |
3800 | reduction clause with inscan modifier. | |
3801 | ||
3179ebae JJ |
3802 | * c-parser.c (c_parser_omp_requires): Call sorry_at on requires |
3803 | clauses other than atomic_default_mem_order. | |
3804 | ||
28567c40 JJ |
3805 | 2018-11-08 Jakub Jelinek <jakub@redhat.com> |
3806 | ||
3807 | * c-parser.c: Include memmode.h. | |
3808 | (c_parser_omp_depobj, c_parser_omp_requires): New functions. | |
3809 | (c_parser_pragma): Handle PRAGMA_OMP_DEPOBJ and PRAGMA_OMP_REQUIRES. | |
3810 | (c_parser_omp_clause_name): Handle nontemporal, in_reduction and | |
3811 | task_reduction clauses. | |
3812 | (c_parser_omp_variable_list): Handle OMP_CLAUSE_{IN,TASK}_REDUCTION. | |
3813 | For OMP_CLAUSE_DEPEND, parse clause operands as either an array | |
3814 | section, or lvalue assignment expression. | |
3815 | (c_parser_omp_clause_if): Handle cancel and simd modifiers. | |
3816 | (c_parser_omp_clause_lastprivate): Parse optional | |
3817 | conditional: modifier. | |
3818 | (c_parser_omp_clause_hint): Require constant integer expression rather | |
3819 | than just integer expression. | |
3820 | (c_parser_omp_clause_defaultmap): Parse new kinds of defaultmap | |
3821 | clause. | |
3822 | (c_parser_omp_clause_reduction): Add IS_OMP and KIND arguments. | |
3823 | Parse reduction modifiers. Pass KIND to c_parser_omp_variable_list. | |
3824 | (c_parser_omp_clause_nontemporal, c_parser_omp_iterators): New | |
3825 | functions. | |
3826 | (c_parser_omp_clause_depend): Parse iterator modifier and handle | |
3827 | iterators. Parse mutexinoutset and depobj kinds. | |
3828 | (c_parser_oacc_all_clauses): Adjust c_parser_omp_clause_reduction | |
3829 | callers. | |
3830 | (c_parser_omp_all_clauses): Likewise. Handle | |
3831 | PRAGMA_OMP_CLAUSE_NONTEMPORAL and | |
3832 | PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION. | |
3833 | (c_parser_omp_atomic): Parse hint and memory order clauses. Handle | |
3834 | default memory order from requires directive if any. Adjust | |
3835 | c_finish_omp_atomic caller. | |
3836 | (c_parser_omp_critical): Allow comma in between (name) and hint clause. | |
3837 | (c_parser_omp_flush): Parse flush with memory-order-clause. | |
3838 | (c_parser_omp_for_loop): Allow NE_EXPR even in | |
3839 | OpenMP loops, adjust c_finish_omp_for caller. | |
3840 | (OMP_SIMD_CLAUSE_MASK): Add if and nontemporal clauses. | |
3841 | (c_parser_omp_master): Add p_name, mask and cclauses arguments. | |
3842 | Allow to be called while parsing combined parallel master. | |
3843 | Parse combined master taskloop{, simd}. | |
3844 | (c_parser_omp_parallel): Parse combined | |
3845 | parallel master{, taskloop{, simd}} constructs. | |
3846 | (OMP_TASK_CLAUSE_MASK): Add in_reduction clause. | |
3847 | (OMP_TASKGROUP_CLAUSE_MASK): Define. | |
3848 | (c_parser_omp_taskgroup): Add LOC argument. Parse taskgroup clauses. | |
3849 | (OMP_TASKWAIT_CLAUSE_MASK): Define. | |
3850 | (c_parser_omp_taskwait): Handle taskwait with depend clauses. | |
3851 | (c_parser_omp_teams): Force a BIND_EXPR with BLOCK | |
3852 | around teams body. Use SET_EXPR_LOCATION. | |
3853 | (c_parser_omp_target_data): Allow target data | |
3854 | with only use_device_ptr clauses. | |
3855 | (c_parser_omp_target): Use SET_EXPR_LOCATION. Set | |
3856 | OMP_REQUIRES_TARGET_USED bit in omp_requires_mask. | |
3857 | (c_parser_omp_requires): New function. | |
3858 | (c_finish_taskloop_clauses): New function. | |
3859 | (OMP_TASKLOOP_CLAUSE_MASK): Add reduction and in_reduction clauses. | |
3860 | (c_parser_omp_taskloop): Use c_finish_taskloop_clauses. Add forward | |
3861 | declaration. Disallow in_reduction clause when combined with parallel | |
3862 | master. | |
3863 | (c_parser_omp_construct): Adjust c_parser_omp_master and | |
3864 | c_parser_omp_taskgroup callers. | |
3865 | * c-typeck.c (c_finish_omp_cancel): Diagnose if clause with modifier | |
3866 | other than cancel. | |
3867 | (handle_omp_array_sections_1): Handle OMP_CLAUSE_{IN,TASK}_REDUCTION | |
3868 | like OMP_CLAUSE_REDUCTION. | |
3869 | (handle_omp_array_sections): Likewise. Call save_expr on array | |
3870 | reductions before calling build_index_type. Handle depend clauses | |
3871 | with iterators. | |
3872 | (struct c_find_omp_var_s): New type. | |
3873 | (c_find_omp_var_r, c_omp_finish_iterators): New functions. | |
3874 | (c_finish_omp_clauses): Don't diagnose nonmonotonic clause | |
3875 | with static, runtime or auto schedule kinds. Call save_expr for whole | |
3876 | array reduction sizes. Diagnose reductions with zero sized elements | |
3877 | or variable length structures. Diagnose nogroup clause used with | |
3878 | reduction clause(s). Handle depend clause with | |
3879 | OMP_CLAUSE_DEPEND_DEPOBJ. Diagnose bit-fields. Require | |
3880 | omp_depend_t type for OMP_CLAUSE_DEPEND_DEPOBJ kinds and | |
3881 | some different type for other kinds. Use build_unary_op with | |
3882 | ADDR_EXPR and build_indirect_ref instead of c_mark_addressable. | |
3883 | Handle depend clauses with iterators. Remove no longer needed special | |
3884 | case that predetermined const qualified vars may be specified in | |
3885 | firstprivate clause. Complain if const qualified vars are mentioned | |
3886 | in data-sharing clauses other than firstprivate or shared. Use | |
3887 | error_at with OMP_CLAUSE_LOCATION (c) as first argument instead of | |
3888 | error. Formatting fix. Handle OMP_CLAUSE_NONTEMPORAL and | |
3889 | OMP_CLAUSE_{IN,TASK}_REDUCTION. Allow any lvalue as | |
3890 | OMP_CLAUSE_DEPEND operand (besides array section), adjust diagnostics. | |
3891 | ||
7e2de6df DM |
3892 | 2018-10-29 David Malcolm <dmalcolm@redhat.com> |
3893 | ||
3894 | * c-decl.c (implicit_decl_warning): Update "is there a suggestion" | |
3895 | logic for change to name_hint::operator bool. | |
3896 | (undeclared_variable): Likewise. | |
3897 | * c-parser.c (c_parser_declaration_or_fndef): Likewise. | |
3898 | (c_parser_parameter_declaration): Likewise. | |
3899 | ||
9f936c86 JM |
3900 | 2018-10-17 Joseph Myers <joseph@codesourcery.com> |
3901 | ||
3902 | * c-errors.c (pedwarn_c11): New function. | |
3903 | * c-parser.c (disable_extension_diagnostics): Save | |
3904 | warn_c11_c2x_compat and set it to 0. | |
3905 | (restore_extension_diagnostics): Restore warn_c11_c2x_compat. | |
3906 | (c_parser_static_assert_declaration_no_semi): Handle | |
3907 | _Static_assert without string constant. | |
3908 | * c-tree.h (pedwarn_c11): New prototype. | |
3909 | ||
033eb567 DM |
3910 | 2018-10-17 David Malcolm <dmalcolm@redhat.com> |
3911 | ||
3912 | * Make-lang.in (selftest-c): New. | |
3913 | (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb) | |
3914 | (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move here | |
3915 | from gcc/Makefile.in. | |
3916 | ||
0edf3afe RB |
3917 | 2018-10-02 Richard Biener <rguenther@suse.de> |
3918 | ||
3919 | * c-decl.c (warn_if_shadowing): Do not test DECL_FROM_INLINE. | |
3920 | ||
8313a764 JM |
3921 | 2018-09-26 Joseph Myers <joseph@codesourcery.com> |
3922 | ||
3923 | PR c/87390 | |
3924 | * c-typeck.c (build_binary_op): Use excess precision for | |
3925 | comparisons of integers and floating-point for C11 and later. | |
3926 | ||
ce6f0888 MJ |
3927 | 2018-09-26 Martin Jambor <mjambor@suse.cz> |
3928 | ||
3929 | PR c/87347 | |
3930 | * c-parser.c (warn_for_abs): Bail out if TYPE_ARG_TYPES is NULL. Fix | |
ab20d992 | 3931 | comment. |
ce6f0888 | 3932 | |
9c4a4b3c DM |
3933 | 2018-09-17 David Malcolm <dmalcolm@redhat.com> |
3934 | ||
3935 | * c-objc-common.c (range_label_for_type_mismatch::get_text): | |
3936 | Update for new param. | |
3937 | * c-typeck.c (maybe_range_label_for_tree_type_mismatch::get_text): | |
3938 | Likewise. | |
3939 | ||
80c6d1f4 MJ |
3940 | 2018-09-17 Martin Jambor <mjambor@suse.cz> |
3941 | ||
3942 | PR c/63886 | |
3943 | * c-parser.c: (warn_for_abs): New function. | |
3944 | (c_parser_postfix_expression_after_primary): Call it. | |
3945 | ||
4a426e36 BE |
3946 | 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de> |
3947 | ||
3948 | * c-typeck.c (digest_init): Shorten overlength strings. | |
3949 | ||
6d900107 BE |
3950 | 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de> |
3951 | ||
3952 | * c-decl.c (finish_decl): Call complete_flexible_array_elts. | |
3953 | ||
b5764229 BE |
3954 | 2018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de> |
3955 | ||
3956 | * c-decl.c (finish_decl): Call braced_list_to_string here ... | |
3957 | * c-parser.c (c_parser_declaration_or_fndef): ... instead of here. | |
3958 | ||
22eea6b2 AM |
3959 | 2018-08-30 Alexander Monakov <amonakov@ispras.ru> |
3960 | ||
3961 | * gimple-parser.c (c_parser_gimple_binary_expression): Accept infix | |
3962 | "__MULT_HIGHPART" for MULT_HIGHPART_EXPR. | |
3963 | ||
85204e23 DM |
3964 | 2018-08-27 David Malcolm <dmalcolm@redhat.com> |
3965 | ||
3966 | PR 87091 | |
3967 | * c-decl.c (implicitly_declare): Update call to | |
3968 | maybe_add_include_fixit to suggest overriding the location, as it | |
3969 | is for a note. | |
3970 | * c-objc-common.c (c_tree_printer): Update for conversion of | |
3971 | show_caret_p to a tri-state. | |
3972 | ||
3d78e008 ML |
3973 | 2018-08-27 Martin Liska <mliska@suse.cz> |
3974 | ||
3975 | * c-decl.c (locate_old_decl): Use new function | |
92a285c1 ML |
3976 | fndecl_built_in_p and remove check for FUNCTION_DECL if |
3977 | possible. | |
3d78e008 ML |
3978 | (diagnose_mismatched_decls): Likewise. |
3979 | (merge_decls): Likewise. | |
3980 | (warn_if_shadowing): Likewise. | |
3981 | (pushdecl): Likewise. | |
3982 | (implicitly_declare): Likewise. | |
3983 | * c-parser.c (c_parser_postfix_expression_after_primary): Likewise. | |
3984 | * c-tree.h (C_DECL_ISNT_PROTOTYPE): Likewise. | |
3985 | * c-typeck.c (build_function_call_vec): Likewise. | |
3986 | (convert_arguments): Likewise. | |
3987 | ||
097f82ec DM |
3988 | 2018-08-20 David Malcolm <dmalcolm@redhat.com> |
3989 | ||
3990 | PR other/84889 | |
3991 | * c-decl.c (pushtag): Add auto_diagnostic_group instance. | |
3992 | (diagnose_mismatched_decls): Likewise, in various places. | |
3993 | (warn_if_shadowing): Likewise. | |
3994 | (implicit_decl_warning): Likewise. | |
3995 | (implicitly_declare): Likewise. | |
3996 | (undeclared_variable): Likewise. | |
3997 | (declare_label): Likewise. | |
3998 | (grokdeclarator): Likewise. | |
3999 | (start_function): Likewise. | |
4000 | * c-parser.c (c_parser_declaration_or_fndef): Likewise. | |
4001 | (c_parser_parameter_declaration): Likewise. | |
4002 | (c_parser_binary_expression): Likewise. | |
4003 | * c-typeck.c (c_expr_sizeof_expr): Likewise. | |
4004 | (parser_build_binary_op): Likewise. | |
4005 | (build_unary_op): Likewise. | |
4006 | (error_init): Likewise. | |
4007 | (pedwarn_init): Likewise. | |
4008 | (warning_init): Likewise. | |
4009 | (convert_for_assignment): Likewise. | |
4010 | ||
96e6ae57 DM |
4011 | 2018-08-15 David Malcolm <dmalcolm@redhat.com> |
4012 | ||
4013 | * c-objc-common.c: Include "gcc-rich-location.h". | |
4014 | (c_tree_printer): Move implemenation of '%T' to... | |
4015 | (print_type): ...this new function. | |
4016 | (range_label_for_type_mismatch::get_text): New function. | |
4017 | * c-typeck.c (convert_for_assignment): Add type labels to the rhs | |
4018 | range for the various ic_argpass cases. | |
4019 | (class maybe_range_label_for_tree_type_mismatch): New class. | |
4020 | (build_binary_op): Use it when calling binary_op_error. | |
4021 | ||
0cd020ae | 4022 | 2018-08-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
ab20d992 | 4023 | |
0cd020ae PK |
4024 | * c-decl.c (start_decl): Do not warn if variables is named as main |
4025 | and is a local variable. | |
4026 | ||
72733314 IS |
4027 | 2018-08-15 Iain Sandoe <iain@sandoe.co.uk> |
4028 | ||
4029 | PR c/19315 | |
4030 | * c-decl.c (finish_decl): Don't add the 'extern' storage class to | |
4031 | objects of unknown size. | |
4032 | ||
23aa9f7c MS |
4033 | 2018-08-13 Martin Sebor <msebor@redhat.com> |
4034 | ||
4035 | PR tree-optimization/71625 | |
4036 | * c-parser.c (c_parser_declaration_or_fndef): Call | |
4037 | braced_list_to_string. | |
4038 | ||
e5e7e50d BH |
4039 | 2018-08-03 Bogdan Harjoc <harjoc@gmail.com> |
4040 | ||
4041 | PR c/86690 | |
4042 | * c-typeck.c (lookup_field): Do not use TYPE_LANG_SPECIFIC after | |
4043 | errors. | |
4044 | ||
8a45b051 MS |
4045 | 2018-08-01 Martin Sebor <msebor@redhat.com> |
4046 | ||
4047 | PR tree-optimization/86650 | |
4048 | * c-objc-common.c (c_tree_printer): Move usage of EXPR_LOCATION (t) | |
4049 | and TREE_BLOCK (t) from within percent_K_format to this callsite. | |
4050 | ||
5922dcb5 JJ |
4051 | 2018-08-01 Jakub Jelinek <jakub@redhat.com> |
4052 | ||
4053 | PR c/85704 | |
4054 | * c-typeck.c (init_field_decl_cmp): New function. | |
4055 | (output_pending_init_elements): Use it for field comparisons | |
4056 | instead of pure bit_position comparisons. | |
4057 | ||
9b452033 JJ |
4058 | 2018-07-12 Jakub Jelinek <jakub@redhat.com> |
4059 | ||
4060 | * c-decl.c (c_decl_attributes): Don't diagnose vars without mappable | |
4061 | type here, instead add "omp declare target implicit" attribute. | |
4062 | (finish_decl): Diagnose vars without mappable type here. | |
4063 | ||
ab20d992 JJ |
4064 | 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com> |
4065 | Thomas Schwinge <thomas@codesourcery.com> | |
829c6349 CLT |
4066 | Cesar Philippidis <cesar@codesourcery.com> |
4067 | ||
4068 | * c-parser.c (c_parser_omp_clause_name): Add support for finalize | |
4069 | and if_present. Make present_or_{copy,copyin,copyout,create} aliases | |
4070 | to their non-present_or_* counterparts. Make 'self' an alias to | |
4071 | PRAGMA_OACC_CLAUSE_HOST. | |
4072 | (c_parser_oacc_data_clause): Update GOMP mappings for | |
4073 | PRAGMA_OACC_CLAUSE_{COPY,COPYIN,COPYOUT,CREATE,DELETE}. Remove | |
4074 | PRAGMA_OACC_CLAUSE_{SELF,PRESENT_OR_*}. | |
4075 | (c_parser_oacc_all_clauses): Handle finalize and if_present clauses. | |
4076 | Remove support for present_or_* clauses. | |
4077 | (OACC_KERNELS_CLAUSE_MASK): Remove PRESENT_OR_* clauses. | |
4078 | (OACC_PARALLEL_CLAUSE_MASK): Likewise. | |
4079 | (OACC_DECLARE_CLAUSE_MASK): Likewise. | |
4080 | (OACC_DATA_CLAUSE_MASK): Likewise. | |
4081 | (OACC_ENTER_DATA_CLAUSE_MASK): Remove PRESENT_OR_* clauses. | |
4082 | (OACC_EXIT_DATA_CLAUSE_MASK): Add FINALIZE clause. | |
4083 | (OACC_UPDATE_CLAUSE_MASK): Remove SELF, add IF_PRESENT. | |
4084 | (c_parser_oacc_declare): Remove PRESENT_OR_* clauses. | |
4085 | * c-typeck.c (c_finish_omp_clauses): Handle IF_PRESENT and FINALIZE. | |
4086 | ||
e197e64e KV |
4087 | 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org> |
4088 | ||
4089 | * c-typeck.c (build_unary_op): Handle ABSU_EXPR; | |
4090 | * gimple-parser.c (c_parser_gimple_statement): Likewise. | |
4091 | (c_parser_gimple_unary_expression): Likewise. | |
4092 | ||
487f2f61 JJ |
4093 | 2018-06-15 Jakub Jelinek <jakub@redhat.com> |
4094 | ||
4095 | PR c/86093 | |
4096 | * c-typeck.c (pointer_diff): Cast both pointers to unqualified types | |
4097 | before doing POINTER_DIFF_EXPR. | |
4098 | ||
e4d44a37 MP |
4099 | 2018-06-07 Marek Polacek <polacek@redhat.com> |
4100 | ||
4101 | PR c/85318 | |
4102 | * c-decl.c (check_for_loop_decls): Add -Wc90-c99-compat warning about | |
4103 | for loop initial declarations. | |
4104 | ||
b67b9225 DP |
4105 | 2018-05-30 David Pagan <dave.pagan@oracle.com> |
4106 | ||
4107 | PR c/55976 | |
4108 | * c-decl.c (grokdeclarator): Update check for return type warnings. | |
4109 | (start_function): Likewise. | |
4110 | (finish_function): Likewise. | |
4111 | * c-typeck.c (c_finish_return): Update check for return type warnings. | |
4112 | Pass OPT_Wreturn_type to pedwarn when appropriate. | |
4113 | ||
c566cc9f RS |
4114 | 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org> |
4115 | ||
4116 | * gimple-parser.c (c_parser_gimple_postfix_expression): Remove | |
4117 | __FMA_EXPR handlng. | |
4118 | ||
e4f81565 RS |
4119 | 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org> |
4120 | ||
4121 | * gimple-parser.c: Include internal-fn.h. | |
4122 | (c_parser_gimple_statement): Treat a leading CPP_DOT as a call. | |
4123 | (c_parser_gimple_call_internal): New function. | |
4124 | (c_parser_gimple_postfix_expression): Use it to handle CPP_DOT. | |
4125 | Fix typos in comment. | |
4126 | ||
79e7b1fe JJ |
4127 | 2018-05-10 Jakub Jelinek <jakub@redhat.com> |
4128 | ||
4129 | PR c++/85662 | |
4130 | * c-fold.c (c_fully_fold_internal): Use fold_offsetof rather than | |
4131 | fold_offsetof_1, pass TREE_TYPE (expr) as TYPE to it and drop the | |
4132 | fold_convert_loc. | |
4133 | * c-typeck.c (build_unary_op): Use fold_offsetof rather than | |
4134 | fold_offsetof_1, pass argtype as TYPE to it and drop the | |
4135 | fold_convert_loc. | |
4136 | ||
f7584c81 DP |
4137 | 2018-05-02 David Pagan <dave.pagan@oracle.com> |
4138 | ||
4139 | PR c/30552 | |
4140 | * c-decl.c (old_style_parameter_scope): New function. | |
4141 | * c-parser.c (c_parser_postfix_expression): Check for statement | |
4142 | expressions in old-style function parameter list declarations. | |
4143 | * c-parser.h (old_style_parameter_scope): New extern declaration. | |
4144 | ||
b33a0cb3 JJ |
4145 | 2018-04-25 Jakub Jelinek <jakub@redhat.com> |
4146 | ||
4147 | PR sanitizer/84307 | |
4148 | * c-decl.c (build_compound_literal): Call pushdecl (decl) even when | |
4149 | it is not TREE_STATIC. | |
4150 | * c-typeck.c (c_mark_addressable) <case COMPOUND_LITERAL_EXPR>: Mark | |
4151 | not just the COMPOUND_LITERAL_EXPR node itself addressable, but also | |
4152 | its COMPOUND_LITERAL_EXPR_DECL. | |
4153 | ||
c5c5822a JM |
4154 | 2018-03-21 Joseph Myers <joseph@codesourcery.com> |
4155 | ||
4156 | * c-parser.c (c_parser_postfix_expression): For __builtin_tgmath | |
4157 | where all functions return the same _FloatN or _FloatNx type, | |
4158 | treat integer types as _Float64 instead of double. | |
4159 | ||
aa1c9429 JJ |
4160 | 2018-03-21 Jakub Jelinek <jakub@redhat.com> |
4161 | ||
4162 | PR c/84999 | |
4163 | * c-typeck.c (build_binary_op): If c_common_type_for_size fails when | |
4164 | building vector comparison, diagnose it and return error_mark_node. | |
4165 | ||
9bb45a95 JJ |
4166 | 2018-03-15 Jakub Jelinek <jakub@redhat.com> |
4167 | ||
4168 | PR c/84853 | |
4169 | * c-typeck.c (build_binary_op) <case RSHIFT_EXPR, case LSHIFT_EXPR>: | |
4170 | If code1 is INTEGER_TYPE, only allow code0 VECTOR_TYPE if it has | |
4171 | INTEGER_TYPE element type. | |
4172 | ||
ada6bad9 DP |
4173 | 2018-03-13 David Pagan <dave.pagan@oracle.com> |
4174 | ||
4175 | PR c/46921 | |
4176 | * c-typeck.c (output_init_element): Ensure field initializer | |
4177 | expression is always evaluated if there are side effects. | |
4178 | ||
849bbdb9 JJ |
4179 | 2018-03-06 Jakub Jelinek <jakub@redhat.com> |
4180 | ||
4181 | PR c/84721 | |
4182 | * c-parser.c (add_debug_begin_stmt): Don't add DEBUG_BEGIN_STMT if | |
4183 | !building_stmt_list_p (). | |
4184 | ||
d74641bd RS |
4185 | 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org> |
4186 | ||
4187 | PR c/84305 | |
4188 | * c-decl.c (grokdeclarator): Create an anonymous TYPE_DECL | |
4189 | in PARM and TYPENAME contexts too, but attach it to a BIND_EXPR | |
4190 | and include the BIND_EXPR in the list of things that need to be | |
4191 | pre-evaluated. | |
4192 | ||
0444aa9c NS |
4193 | 2018-02-09 Nathan Sidwell <nathan@acm.org> |
4194 | ||
4195 | PR c/84293 | |
4196 | * c-typeck.c (build_indirect_ref, build_c_cast): Pass expr location | |
4197 | to strict_aliasing_warning. | |
4198 | ||
7c30b12a PC |
4199 | 2018-02-02 Paolo Carlini <paolo.carlini@oracle.com> |
4200 | ||
4201 | * c-typeck.c (really_start_incremental_init, push_init_level, | |
4202 | set_nonincremental_init, output_init_element, process_init_element): | |
4203 | Use DECL_UNNAMED_BIT_FIELD. | |
4204 | ||
2be4dfcb MP |
4205 | 2018-01-31 Marek Polacek <polacek@redhat.com> |
4206 | ||
4207 | PR c/81779 | |
4208 | * c-parser.c (c_parser_compound_statement_nostart): Call | |
4209 | expansion_point_location_if_in_system_header. | |
4210 | ||
bb9869d5 DM |
4211 | 2018-01-17 David Malcolm <dmalcolm@redhat.com> |
4212 | ||
4213 | PR c++/83814 | |
4214 | * c-fold.c (fold_for_warn): Move from c-common.c, reducing to just | |
4215 | the C part. | |
4216 | ||
b4923738 JJ |
4217 | 2018-01-13 Jakub Jelinek <jakub@redhat.com> |
4218 | ||
4219 | PR c/83801 | |
4220 | * c-tree.h (decl_constant_value_1): Add a bool argument. | |
4221 | * c-typeck.c (decl_constant_value_1): Add IN_INIT argument, allow | |
4222 | returning a CONSTRUCTOR if it is true. Use error_operand_p. | |
4223 | (decl_constant_value): Adjust caller. | |
4224 | * c-fold.c (c_fully_fold_internal): If in_init, pass true to | |
4225 | decl_constant_value_1 as IN_INIT. Otherwise, punt if | |
4226 | decl_constant_value returns initializer that has BLKmode or | |
4227 | array type. | |
4228 | (c_fully_fold_internal) <case COMPONENT_REF>: Fold if !lval. | |
4229 | ||
928686b1 RS |
4230 | 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org> |
4231 | Alan Hayward <alan.hayward@arm.com> | |
4232 | David Sherwood <david.sherwood@arm.com> | |
4233 | ||
4234 | * c-typeck.c (comptypes_internal, build_binary_op): Handle polynomial | |
4235 | TYPE_VECTOR_SUBPARTS. | |
4236 | ||
85ec4feb JJ |
4237 | 2018-01-03 Jakub Jelinek <jakub@redhat.com> |
4238 | ||
4239 | Update copyright years. | |
4240 | ||
913884f7 JJ |
4241 | 2018-01-01 Jakub Jelinek <jakub@redhat.com> |
4242 | ||
4243 | PR c/83595 | |
4244 | * c-parser.c (c_parser_braced_init, c_parser_initelt, | |
4245 | c_parser_conditional_expression, c_parser_cast_expression, | |
4246 | c_parser_sizeof_expression, c_parser_alignof_expression, | |
4247 | c_parser_postfix_expression, c_parser_omp_declare_reduction, | |
4248 | c_parser_transaction_expression): Use set_error () method instead | |
4249 | of setting value member to error_mark_node. | |
4250 | ||
c6cfa2bf MM |
4251 | 2017-12-28 Michael Meissner <meissner@linux.vnet.ibm.com> |
4252 | ||
4253 | * c-decl.c (header_for_builtin_fn): Add integer rounding _Float<N> | |
4254 | and _Float<N>X built-in functions. | |
4255 | ||
11d29d63 JJ |
4256 | 2017-12-22 Jakub Jelinek <jakub@redhat.com> |
4257 | ||
14ec014e JJ |
4258 | PR debug/83550 |
4259 | * c-decl.c (finish_struct): Set DECL_SOURCE_LOCATION on | |
4260 | TYPE_STUB_DECL and call rest_of_type_compilation before processing | |
4261 | incomplete vars rather than after it. | |
4262 | ||
11d29d63 JJ |
4263 | PR debug/83547 |
4264 | * c-typeck.c (c_finish_stmt_expr): Ignore !TREE_SIDE_EFFECTS as | |
4265 | indicator of ({ }), instead skip all trailing DEBUG_BEGIN_STMTs first, | |
4266 | and consider empty ones if there are no other stmts. For | |
4267 | -Wunused-value walk all statements before the one only followed by | |
4268 | DEBUG_BEGIN_STMTs. | |
4269 | ||
170a8bd6 | 4270 | 2017-12-22 Mike Stump <mikestump@comcast.net> |
92a285c1 | 4271 | Eric Botcazou <ebotcazou@adacore.com> |
170a8bd6 EB |
4272 | |
4273 | * c-parser.c (c_parser_while_statement): Add unroll parameter and | |
4274 | build ANNOTATE_EXPR if present. Add 3rd operand to ANNOTATE_EXPR. | |
4275 | (c_parser_do_statement): Likewise. | |
4276 | (c_parser_for_statement): Likewise. | |
4277 | (c_parser_statement_after_labels): Adjust calls to above. | |
4278 | (c_parse_pragma_ivdep): New static function. | |
4279 | (c_parser_pragma_unroll): Likewise. | |
4280 | (c_parser_pragma) <PRAGMA_IVDEP>: Add support for pragma Unroll. | |
4281 | <PRAGMA_UNROLL>: New case. | |
4282 | ||
01512446 JJ |
4283 | 2017-12-19 Jakub Jelinek <jakub@redhat.com> |
4284 | ||
4285 | * c-typeck.c (comptypes_internal, function_types_compatible_p, | |
4286 | perform_integral_promotions, digest_init): Replace Yoda conditions | |
4287 | with typical order conditions. | |
4288 | * c-decl.c (check_bitfield_type_and_width): Likewise. | |
4289 | ||
c65e18d3 BE |
4290 | 2017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de> |
4291 | ||
4292 | * c-typeck.c (c_safe_arg_type_equiv_p, | |
4293 | c_safe_function_type_cast_p): New function. | |
4294 | (build_c_cast): Implement -Wcast-function-type. | |
4295 | ||
b7280579 RB |
4296 | 2017-12-14 Richard Biener <rguenther@suse.de> |
4297 | ||
4298 | PR c/83415 | |
4299 | * c-fold.c (c_fully_fold_internal): Treat VIEW_CONVERT_EXPR | |
4300 | like REALPART_EXPR for the behavior of whether its operand | |
4301 | is an lvalue. | |
4302 | ||
49e6a6c0 MP |
4303 | 2017-12-12 Marek Polacek <polacek@redhat.com> |
4304 | ||
4305 | PR c/82679 | |
4306 | * c-decl.c (grokdeclarator): Check declspecs insted of atomicp. | |
4307 | ||
ab20d992 | 4308 | 2017-12-12 Alexandre Oliva <aoliva@redhat.com> |
96a95ac1 AO |
4309 | |
4310 | * c-objc-common.h (LANG_HOOKS_EMITS_BEGIN_STMT): Redefine as true. | |
4311 | * c-parser.c (add_debug_begin_stmt): New. | |
4312 | (c_parser_declaration_or_fndef): Call it. | |
4313 | (c_parser_compound_statement_nostart): Likewise. | |
4314 | (c_parser_statement_after_labels): Likewise. | |
4315 | * c-typeck (c_finish_stmt_expr): Skip begin stmts markers. | |
4316 | ||
4b2b493f JM |
4317 | 2017-12-07 Joseph Myers <joseph@codesourcery.com> |
4318 | ||
4319 | * c-decl.c (build_compound_literal): Add parameter alignas_align | |
4320 | and set alignment of decl if nonzero. | |
4321 | * c-parser.c (c_keyword_starts_typename): Allow RID_ALIGNAS. | |
4322 | (c_parser_declspecs): Allow RID_ALIGNAS to follow a type, like a | |
4323 | qualifier. | |
4324 | (c_parser_struct_declaration): Update syntax comment. | |
4325 | (c_parser_type_name): Add alignas_ok argument and pass it to | |
4326 | c_parser_declspecs. | |
4327 | (c_parser_cast_expression): Pass true to c_parser_type_name and | |
4328 | give error if a cast used an _Alignas specifier. | |
4329 | (c_parser_sizeof_expression): Pass true to c_parser_type_name and | |
4330 | give error if sizeof (type-name) used an _Alignas specifier. | |
4331 | (c_parser_alignof_expression): Pass true to c_parser_type_name and | |
4332 | give error if _Alignof (type-name) used an _Alignas specifier. | |
4333 | (c_parser_postfix_expression_after_paren_type): Check specified | |
4334 | alignment for a compound literal and pass it to | |
4335 | build_compound_literal. | |
4336 | * c-parser.h (c_parser_type_name): Update prototype. | |
4337 | * c-tree.h (build_compound_literal): Update prototype. | |
4338 | ||
5d9ae53d MS |
4339 | 2017-12-07 Martin Sebor <msebor@redhat.com> |
4340 | ||
4341 | PR c/81544 | |
4342 | * c-decl.c (c_decl_attributes): Look up existing declaration and | |
4343 | pass it to decl_attributes. | |
4344 | ||
c79144f8 DM |
4345 | 2017-12-06 David Malcolm <dmalcolm@redhat.com> |
4346 | ||
4347 | PR c/83236 | |
4348 | * c-decl.c (lookup_name_fuzzy): Don't suggest names that are | |
4349 | reserved for use by the implementation. | |
4350 | ||
613bc14f DM |
4351 | 2017-12-06 David Malcolm <dmalcolm@redhat.com> |
4352 | ||
4353 | * c-decl.c: Include "c-family/c-spellcheck.h". | |
4354 | ||
05abad4c ML |
4355 | 2017-12-05 Martin Liska <mliska@suse.cz> |
4356 | Jakub Jelinek <jakub@redhat.com> | |
4357 | ||
4358 | * c-typeck.c (pointer_diff): Add new argument and instrument | |
4359 | pointer subtraction. | |
4360 | (build_binary_op): Similar for pointer comparison. | |
4361 | ||
cc6534d4 JJ |
4362 | 2017-12-01 Jakub Jelinek <jakub@redhat.com> |
4363 | ||
65791f42 JJ |
4364 | PR c/79153 |
4365 | * c-parser.c: Include tree-iterator.h. | |
4366 | (c_parser_switch_statement): Emit LABEL_EXPR for the break label | |
4367 | into SWITCH_BODY instead of after it and set SWITCH_BREAK_LABEL_P | |
4368 | on it. | |
4369 | ||
cc6534d4 JJ |
4370 | PR c/83222 |
4371 | * c-tree.h (decl_constant_value_1): Declare. | |
4372 | * c-typeck.c (decl_constant_value_1): New function. | |
4373 | (decl_constant_value): Use it. | |
4374 | * c-fold.c (c_fully_fold_internal): If in_init, use | |
4375 | decl_constant_value_1 instead of decl_constant_value. | |
4376 | ||
5de73c05 JJ |
4377 | 2017-11-30 Jakub Jelinek <jakub@redhat.com> |
4378 | ||
4379 | * c-parser.c (c_parser_postfix_expression): Use ; instead of ;;. | |
4380 | ||
058f0b9e JJ |
4381 | 2017-11-28 Jakub Jelinek <jakub@redhat.com> |
4382 | ||
4383 | PR sanitizer/81275 | |
4384 | * c-typeck.c (c_finish_case): Set SWITCH_ALL_CASES_P if | |
4385 | c_switch_covers_all_cases_p returns true. | |
4386 | ||
5e9d6aa4 | 4387 | 2017-11-28 Julia Koval <julia.koval@intel.com> |
92a285c1 | 4388 | Sebastian Peryt <sebastian.peryt@intel.com> |
5e9d6aa4 JK |
4389 | |
4390 | * Make-lang.in (c/c-array-notation.o): Remove. | |
4391 | * c-array-notation.c: Delete. | |
4392 | * c-decl.c: Remove cilkplus condition. | |
4393 | * c-parser.c (c_parser_cilk_simd, c_parser_cilk_for, | |
4394 | c_parser_cilk_verify_simd, c_parser_array_notation, | |
4395 | c_parser_cilk_clause_vectorlength, c_parser_cilk_grainsize, | |
4396 | c_parser_cilk_simd_fn_vector_attrs, | |
4397 | c_finish_cilk_simd_fn_tokens): Delete. | |
4398 | (c_parser_declaration_or_fndef): Remove cilkplus condition. | |
4399 | (c_parser_direct_declarator_inner): Ditto. | |
4400 | (CILK_SIMD_FN_CLAUSE_MASK): Delete. | |
4401 | (c_parser_attributes, c_parser_compound_statement, | |
4402 | c_parser_statement_after_labels, c_parser_if_statement, | |
4403 | c_parser_switch_statement, c_parser_while_statement, | |
4404 | c_parser_do_statement, c_parser_for_statement, | |
4405 | c_parser_unary_expression, c_parser_postfix_expression, | |
4406 | c_parser_postfix_expression_after_primary, | |
4407 | c_parser_pragma, c_parser_omp_clause_name, c_parser_omp_all_clauses, | |
4408 | c_parser_omp_for_loop, c_finish_omp_declare_simd): Remove cilkplus | |
4409 | support. | |
4410 | * c-typeck.c (build_array_ref, build_function_call_vec, | |
4411 | convert_arguments, | |
4412 | lvalue_p, build_compound_expr, c_finish_return, c_finish_if_stmt, | |
4413 | c_finish_loop, build_binary_op): Remove cilkplus support. | |
4414 | ||
9e851845 JJ |
4415 | 2017-11-28 Jakub Jelinek <jakub@redhat.com> |
4416 | ||
4417 | * c-typeck.c (c_start_case): Build SWITCH_EXPR using build2 instead | |
4418 | of build3. | |
4419 | ||
ab20d992 | 4420 | 2017-11-14 Boris Kolpackov <boris@codesynthesis.com> |
8c7dbea9 BK |
4421 | |
4422 | * Make-lang.in (c.install-plugin): Install backend import library. | |
4423 | ||
41521dee JJ |
4424 | 2017-11-23 Jakub Jelinek <jakub@redhat.com> |
4425 | ||
4426 | * c-parser.c (c_parser_omp_declare_simd): Reject declare simd in | |
4427 | pragma_stmt context. | |
4428 | ||
ac9effed EB |
4429 | 2017-11-23 Mike Stump <mikestump@comcast.net> |
4430 | Eric Botcazou <ebotcazou@adacore.com> | |
4431 | ||
4432 | * c-parser.c (c_parser_while_statement): Pass 3rd operand to | |
4433 | ANNOTATE_EXPR. | |
4434 | (c_parser_do_statement): Likewise. | |
4435 | (c_parser_for_statement): Likewise. | |
4436 | ||
ce95abc4 DM |
4437 | 2017-11-22 David Malcolm <dmalcolm@redhat.com> |
4438 | ||
4439 | PR c++/62170 | |
4440 | * c-objc-common.c (c_tree_printer): Convert penultimate param from | |
4441 | bool to bool *. Within '%T' handling, if showing an "aka", use | |
4442 | "quoted" param to add appropriate quoting. | |
4443 | ||
974aedcc MP |
4444 | 2017-11-22 Marek Polacek <polacek@redhat.com> |
4445 | ||
4446 | PR c++/60336 | |
4447 | PR middle-end/67239 | |
4448 | PR target/68355 | |
4449 | * c-decl.c (grokdeclarator): Set DECL_PADDING_P on unnamed bit-fields. | |
4450 | ||
d4300cc6 DM |
4451 | 2017-11-21 David Malcolm <dmalcolm@redhat.com> |
4452 | ||
4453 | PR c/83056 | |
4454 | * c-decl.c (lookup_name_fuzzy): Don't suggest names that came from | |
4455 | earlier failed lookups. | |
4456 | ||
1af4ebf5 MG |
4457 | 2017-11-21 Marc Glisse <marc.glisse@inria.fr> |
4458 | ||
4459 | * c-fold.c (c_fully_fold_internal): Handle POINTER_DIFF_EXPR. | |
4460 | * c-typeck.c (pointer_diff): Use POINTER_DIFF_EXPR. | |
4461 | ||
26edace6 DM |
4462 | 2017-11-20 David Malcolm <dmalcolm@redhat.com> |
4463 | ||
4464 | PR c/81404 | |
4465 | * c-decl.c: Include "c-family/known-headers.h". | |
4466 | (get_c_name_hint): Rename to get_stdlib_header_for_name and move | |
4467 | to known-headers.cc. | |
4468 | (class suggest_missing_header): Move to known-header.h. | |
4469 | (lookup_name_fuzzy): Call get_c_stdlib_header_for_name rather | |
4470 | than get_c_name_hint. | |
4471 | ||
b1212255 DM |
4472 | 2017-11-20 David Malcolm <dmalcolm@redhat.com> |
4473 | ||
4474 | * c-decl.c (get_c_name_hint): New function. | |
4475 | (class suggest_missing_header): New class. | |
4476 | (lookup_name_fuzzy): Call get_c_name_hint and use it to | |
4477 | suggest missing headers to the user. | |
4478 | ||
6c7a259b DM |
4479 | 2017-11-20 David Malcolm <dmalcolm@redhat.com> |
4480 | ||
4481 | * c-decl.c: Define INCLUDE_UNIQUE_PTR before including system.h. | |
4482 | Include "c-family/name-hint.h" | |
4483 | (implicit_decl_warning): Convert "hint" from | |
4484 | const char * to name_hint. Pass location to | |
4485 | lookup_name_fuzzy. Suppress any deferred diagnostic if the | |
4486 | warning was not printed. | |
4487 | (undeclared_variable): Likewise for "guessed_id". | |
4488 | (lookup_name_fuzzy): Convert return type from const char * | |
4489 | to name_hint. Add location_t param. | |
4490 | * c-parser.c: Define INCLUDE_UNIQUE_PTR before including system.h. | |
4491 | Include "c-family/name-hint.h" | |
4492 | (c_parser_declaration_or_fndef): Convert "hint" from | |
4493 | const char * to name_hint. Pass location to lookup_name_fuzzy. | |
4494 | (c_parser_parameter_declaration): Likewise. | |
4495 | ||
f9c59f7e JJ |
4496 | 2017-11-19 Jakub Jelinek <jakub@redhat.com> |
4497 | ||
4498 | PR c/66618 | |
4499 | PR c/69960 | |
4500 | * c-parser.c (c_parser_omp_atomic): Pass true as LVAL to c_fully_fold | |
4501 | where needed. | |
4502 | * c-typeck.c (build_unary_op, build_modify_expr, build_asm_expr, | |
4503 | handle_omp_array_sections): Likewise. | |
4504 | (digest_init): Don't call decl_constant_value_for_optimization. | |
4505 | * c-tree.h (decl_constant_value_for_optimization): Removed. | |
4506 | * c-fold.c (c_fold_array_ref): New function. | |
4507 | (c_fully_fold_internal): Add LVAL argument, propagate it through | |
4508 | recursive calls. For VAR_P call decl_constant_value and | |
4509 | unshare if not LVAL and either optimizing or IN_INIT. Remove | |
4510 | decl_constant_value_for_optimization calls. If IN_INIT and not LVAL, | |
4511 | fold ARRAY_REF with STRING_CST and INTEGER_CST operands. | |
4512 | (c_fully_fold): Add LVAL argument, pass it through to | |
4513 | c_fully_fold_internal. | |
4514 | (decl_constant_value_for_optimization): Removed. | |
4515 | ||
3ca0dc60 JM |
4516 | 2017-11-15 Joseph Myers <joseph@codesourcery.com> |
4517 | ||
4518 | PR c/81156 | |
4519 | * c-parser.c (check_tgmath_function): New function. | |
4520 | (enum tgmath_parm_kind): New enum. | |
4521 | (c_parser_postfix_expression): Handle __builtin_tgmath. | |
4522 | ||
64a5912c DM |
4523 | 2017-10-31 David Malcolm <dmalcolm@redhat.com> |
4524 | ||
4525 | * c-decl.c (implicit_decl_warning): Update for renaming of | |
4526 | pedwarn_at_rich_loc and warning_at_rich_loc. | |
4527 | (implicitly_declare): Likewise for renaming of inform_at_rich_loc. | |
4528 | (undeclared_variable): Likewise for renaming of error_at_rich_loc. | |
4529 | * c-parser.c (c_parser_declaration_or_fndef): Likewise. | |
4530 | (c_parser_struct_or_union_specifier): Likewise for renaming of | |
4531 | pedwarn_at_rich_loc. | |
4532 | (c_parser_parameter_declaration): Likewise for renaming of | |
4533 | error_at_rich_loc. | |
4534 | * c-typeck.c (build_component_ref): Likewise. | |
4535 | (build_unary_op): Likewise for renaming of inform_at_rich_loc. | |
4536 | (pop_init_level): Likewise for renaming of warning_at_rich_loc. | |
4537 | (set_init_label): Likewise for renaming of error_at_rich_loc. | |
4538 | ||
c1136864 RB |
4539 | 2017-10-30 Richard Biener <rguenther@suse.de> |
4540 | ||
4541 | * gimple-parser.c (c_parser_gimple_statement): Parse conditional | |
4542 | stmts. | |
4543 | ||
ee5fd23a MM |
4544 | 2017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com> |
4545 | ||
4546 | * c-decl.c (header_for_builtin_fn): Add support for copysign, fma, | |
4547 | fmax, fmin, and sqrt _Float<N> and _Float<N>X variants. | |
4548 | ||
1a59ccf2 DM |
4549 | 2017-10-25 David Malcolm <dmalcolm@redhat.com> |
4550 | ||
4551 | PR c/7356 | |
4552 | * c-parser.c (c_parser_declaration_or_fndef): Detect missing | |
4553 | semicolons. | |
4554 | ||
bc1a75dd JJ |
4555 | 2017-10-25 Jakub Jelinek <jakub@redhat.com> |
4556 | ||
4557 | PR libstdc++/81706 | |
4558 | * c-decl.c (merge_decls): Copy "omp declare simd" attributes from | |
4559 | newdecl to corresponding __builtin_ if any. | |
4560 | ||
ff1ff960 PC |
4561 | 2017-10-24 Paolo Carlini <paolo.carlini@oracle.com> |
4562 | ||
4563 | PR c++/82466 | |
4564 | * c-decl.c (diagnose_mismatched_decls): Use | |
4565 | OPT_Wbuiltin_declaration_mismatch. | |
4566 | ||
62e1c678 DM |
4567 | 2017-10-12 David Malcolm <dmalcolm@redhat.com> |
4568 | ||
4569 | * c-parser.c (c_parser_require): Add "type_is_unique" param and | |
4570 | use it to guard calls to maybe_suggest_missing_token_insertion. | |
4571 | (c_parser_parms_list_declarator): Override default value of new | |
4572 | "type_is_unique" param to c_parser_require. | |
4573 | (c_parser_asm_statement): Likewise. | |
4574 | * c-parser.h (c_parser_require): Add "type_is_unique" param, | |
4575 | defaulting to true. | |
4576 | ||
a92f6726 NS |
4577 | 2017-10-11 Nathan Sidwell <nathan@acm.org> |
4578 | ||
4579 | * c-decl.c (grokdeclarator): Check HAS_DECL_ASSEMBLER_NAME_P too. | |
4580 | ||
8e6cdc90 RS |
4581 | 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org> |
4582 | ||
4583 | * c-parser.c (c_parser_cilk_clause_vectorlength): Use wi::to_wide when | |
4584 | operating on trees as wide_ints. | |
4585 | * c-typeck.c (build_c_cast, c_finish_omp_clauses): Likewise. | |
4586 | (c_tree_equal): Likewise. | |
4587 | ||
8139a48e DM |
4588 | 2017-10-04 David Malcolm <dmalcolm@redhat.com> |
4589 | ||
4590 | * c-decl.c (push_parm_decl): Store c_parm's location into the | |
4591 | PARAM_DECL. | |
4592 | (build_c_parm): Add "loc" param and store it within the c_parm. | |
4593 | * c-parser.c (struct c_parser): Add "last_token_location" field. | |
4594 | (c_parser_consume_token): Store location of the token into the | |
4595 | new field. | |
4596 | (c_parser_declaration_or_fndef): Store params into DECL_ARGUMENTS | |
4597 | when handling a FUNCTION_DECL, if it doesn't already have them. | |
4598 | (c_parser_parameter_declaration): Generate a location for the | |
4599 | parameter, and pass it to the call to build_c_parm. | |
4600 | * c-tree.h (struct c_parm): Add field "loc". | |
4601 | (build_c_parm): Add location_t param. | |
4602 | * c-typeck.c (get_fndecl_argument_location): New function. | |
4603 | (inform_for_arg): New function. | |
4604 | (convert_for_assignment): Use inform_for_arg when dealing with | |
4605 | ic_argpass. | |
4606 | ||
2a389958 JJ |
4607 | 2017-09-29 Jakub Jelinek <jakub@redhat.com> |
4608 | ||
7d386d45 JJ |
4609 | * c-decl.c (grokfield): Use SET_DECL_C_BIT_FIELD here if |
4610 | width is non-NULL. | |
4611 | (finish_struct): Test DECL_C_BIT_FIELD instead of DECL_INITIAL, | |
4612 | don't SET_DECL_C_BIT_FIELD here. | |
4613 | ||
2a389958 JJ |
4614 | PR c/82340 |
4615 | * c-decl.c (build_compound_literal): Use c_apply_type_quals_to_decl | |
4616 | instead of trying to set just TREE_READONLY manually. | |
4617 | ||
ebc6a85e TV |
4618 | 2017-09-16 Tom de Vries <tom@codesourcery.com> |
4619 | ||
4620 | PR c/81875 | |
4621 | * c-parser.c (c_parser_omp_for_loop): Fold only operands of cond, not | |
4622 | cond itself. | |
4623 | ||
bb75facd JM |
4624 | 2017-09-15 Joseph Myers <joseph@codesourcery.com> |
4625 | ||
4626 | PR c/82071 | |
4627 | * c-typeck.c (ep_convert_and_check): Just call convert_and_check | |
4628 | for C11. | |
4629 | (build_conditional_expr): For C11, generate result with excess | |
4630 | precision when one argument is an integer and the other is of a | |
4631 | type using excess precision. | |
4632 | ||
1d933576 BE |
4633 | 2017-09-15 Bernd Edlinger <bernd.edlinger@hotmail.de> |
4634 | ||
4635 | * c-typeck.c (build_c_cast): Implement -Wcast-align=strict. | |
4636 | ||
267bbb6f MP |
4637 | 2017-09-13 Marek Polacek <polacek@redhat.com> |
4638 | ||
4639 | PR c/82167 | |
4640 | * c-typeck.c (c_expr_sizeof_expr): Use the type of expr.value rather | |
4641 | than expr.original_type. | |
4642 | ||
6836632e NS |
4643 | 2017-09-12 Nathan Sidwell <nathan@acm.org> |
4644 | ||
4645 | * c-decl.c (field_decl_cmp, resort_data, resort_field_decl_cmp, | |
4646 | resort_sorted_fields): Moved from c-family/c-common.c. | |
4647 | * c-lang.h (struct sorted_fields_type): Moved from c-family/c-common.h. | |
4648 | ||
e035be33 JM |
4649 | 2017-09-01 Joseph Myers <joseph@codesourcery.com> |
4650 | ||
4651 | PR c/82071 | |
4652 | * c-typeck.c (build_atomic_assign): Handle argument with excess | |
4653 | precision. Ensure any EXCESS_PRECISION_EXPR is present in | |
4654 | argument passed to build_binary_op and convert_for_assignment but | |
4655 | not for call to c_fully_fold. | |
4656 | (build_modify_expr): Do not remove EXCESS_PRECISION_EXPR early. | |
4657 | Ensure build_binary_op is called with argument with original | |
4658 | semantic type. Avoid calling c_fully_fold with an | |
4659 | EXCESS_PRECISION_EXPR from build_binary_op. | |
4660 | ||
d2e05fcb JJ |
4661 | 2017-09-01 Jakub Jelinek <jakub@redhat.com> |
4662 | ||
4663 | PR c/81887 | |
4664 | * c-parser.c (c_parser_omp_ordered): Handle -fopenmp-simd. | |
4665 | ||
b397965c RS |
4666 | 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org> |
4667 | Alan Hayward <alan.hayward@arm.com> | |
4668 | David Sherwood <david.sherwood@arm.com> | |
4669 | ||
4670 | * c-typeck.c (build_binary_op): Use SCALAR_TYPE_MODE. | |
4671 | (c_common_type): Likewise. Use as_a <scalar_mode> when setting | |
4672 | m1 and m2 to the signed equivalent of a fixed-point | |
4673 | SCALAR_TYPE_MODE. | |
4674 | ||
14e18d71 DM |
4675 | 2017-08-24 David Malcolm <dmalcolm@redhat.com> |
4676 | ||
4677 | * c-tree.h (c_expr::get_location) Use EXPR_HAS_LOCATION rather | |
4678 | than CAN_HAVE_LOCATION_P when determining whether to use the | |
4679 | location_t value within "value". | |
4680 | ||
7f204c0f DM |
4681 | 2017-08-21 David Malcolm <dmalcolm@redhat.com> |
4682 | ||
4683 | * c-parser.c (c_parser_expr_list): Use c_expr::get_location () | |
4684 | rather than peeking the location of the first token. | |
4685 | * c-tree.h (c_expr::get_location): New method. | |
4686 | ||
2f687306 DM |
4687 | 2017-08-21 David Malcolm <dmalcolm@redhat.com> |
4688 | ||
4689 | * c-typeck.c (build_function_call_vec): Pass arg_loc to call | |
4690 | to check_function_arguments. | |
4691 | ||
3e7b80d7 MP |
4692 | 2017-08-18 Marek Polacek <polacek@redhat.com> |
4693 | ||
4694 | * c-parser.c (c_parser_postfix_expression): Remove unused code. Update | |
4695 | commentary. | |
4696 | ||
00aa1fa2 L |
4697 | 2017-08-18 H.J. Lu <hongjiu.lu@intel.com> |
4698 | ||
4699 | PR c/53037 | |
4700 | * c-decl.c (merge_decls): Also merge DECL_WARN_IF_NOT_ALIGN. | |
4701 | (check_bitfield_type_and_width): Don't allow bit-field with | |
4702 | warn_if_not_aligned type. | |
4703 | ||
da67acb9 MS |
4704 | 2017-08-14 Martin Sebor <msebor@redhat.com> |
4705 | ||
4706 | PR c/81117 | |
4707 | * c-objc-common.c (c_objc_common_init): Handle 'G'. | |
4708 | ||
bb85aa74 MP |
4709 | 2017-08-11 Marek Polacek <polacek@redhat.com> |
4710 | ||
4711 | PR c/81795 | |
4712 | * c-decl.c (pushtag): Only print inform if the warning was printed. | |
4713 | (grokdeclarator): Likewise. | |
4714 | ||
32129a17 DM |
4715 | 2017-08-10 David Malcolm <dmalcolm@redhat.com> |
4716 | ||
4717 | * c-parser.c (c_parser_error): Rename to... | |
4718 | (c_parser_error_richloc): ...this, making static, and adding | |
4719 | "richloc" parameter, passing it to the c_parse_error call, | |
4720 | rather than calling c_parser_set_source_position_from_token. | |
4721 | (c_parser_error): Reintroduce, reimplementing in terms of the | |
4722 | above, converting return type from void to bool. | |
4723 | (class token_pair): New class. | |
4724 | (struct matching_paren_traits): New struct. | |
4725 | (matching_parens): New typedef. | |
4726 | (struct matching_brace_traits): New struct. | |
4727 | (matching_braces): New typedef. | |
4728 | (get_matching_symbol): New function. | |
4729 | (c_parser_require): Add param MATCHING_LOCATION, using it to | |
4730 | highlight matching "opening" tokens for missing "closing" tokens. | |
4731 | (c_parser_skip_until_found): Likewise. | |
4732 | (c_parser_static_assert_declaration_no_semi): Convert explicit | |
4733 | parsing of CPP_OPEN_PAREN and CPP_CLOSE_PAREN to use of | |
4734 | class matching_parens, so that the pertinent open parenthesis is | |
4735 | highlighted when there are problems locating the close | |
4736 | parenthesis. | |
4737 | (c_parser_struct_or_union_specifier): Likewise. | |
4738 | (c_parser_typeof_specifier): Likewise. | |
4739 | (c_parser_alignas_specifier): Likewise. | |
4740 | (c_parser_simple_asm_expr): Likewise. | |
4741 | (c_parser_braced_init): Likewise, for matching_braces. | |
4742 | (c_parser_paren_condition): Likewise, for matching_parens. | |
4743 | (c_parser_switch_statement): Likewise. | |
4744 | (c_parser_for_statement): Likewise. | |
4745 | (c_parser_asm_statement): Likewise. | |
4746 | (c_parser_asm_operands): Likewise. | |
4747 | (c_parser_cast_expression): Likewise. | |
4748 | (c_parser_sizeof_expression): Likewise. | |
4749 | (c_parser_alignof_expression): Likewise. | |
4750 | (c_parser_generic_selection): Likewise. | |
4751 | (c_parser_postfix_expression): Likewise for cases RID_VA_ARG, | |
4752 | RID_OFFSETOF, RID_TYPES_COMPATIBLE_P, RID_AT_SELECTOR, | |
4753 | RID_AT_PROTOCOL, RID_AT_ENCODE, reindenting as necessary. | |
4754 | In case CPP_OPEN_PAREN, pass loc_open_paren to the | |
4755 | c_parser_skip_until_found call. | |
4756 | (c_parser_objc_class_definition): Use class matching_parens as | |
4757 | above. | |
4758 | (c_parser_objc_method_decl): Likewise. | |
4759 | (c_parser_objc_try_catch_finally_statement): Likewise. | |
4760 | (c_parser_objc_synchronized_statement): Likewise. | |
4761 | (c_parser_objc_at_property_declaration): Likewise. | |
4762 | (c_parser_oacc_wait_list): Likewise. | |
4763 | (c_parser_omp_var_list_parens): Likewise. | |
4764 | (c_parser_omp_clause_collapse): Likewise. | |
4765 | (c_parser_omp_clause_default): Likewise. | |
4766 | (c_parser_omp_clause_if): Likewise. | |
4767 | (c_parser_omp_clause_num_threads): Likewise. | |
4768 | (c_parser_omp_clause_num_tasks): Likewise. | |
4769 | (c_parser_omp_clause_grainsize): Likewise. | |
4770 | (c_parser_omp_clause_priority): Likewise. | |
4771 | (c_parser_omp_clause_hint): Likewise. | |
4772 | (c_parser_omp_clause_defaultmap): Likewise. | |
4773 | (c_parser_oacc_single_int_clause): Likewise. | |
4774 | (c_parser_omp_clause_ordered): Likewise. | |
4775 | (c_parser_omp_clause_reduction): Likewise. | |
4776 | (c_parser_omp_clause_schedule): Likewise. | |
4777 | (c_parser_omp_clause_num_teams): Likewise. | |
4778 | (c_parser_omp_clause_thread_limit): Likewise. | |
4779 | (c_parser_omp_clause_aligned): Likewise. | |
4780 | (c_parser_omp_clause_linear): Likewise. | |
4781 | (c_parser_omp_clause_safelen): Likewise. | |
4782 | (c_parser_omp_clause_simdlen): Likewise. | |
4783 | (c_parser_omp_clause_depend): Likewise. | |
4784 | (c_parser_omp_clause_map): Likewise. | |
4785 | (c_parser_omp_clause_device): Likewise. | |
4786 | (c_parser_omp_clause_dist_schedule): Likewise. | |
4787 | (c_parser_omp_clause_proc_bind): Likewise. | |
4788 | (c_parser_omp_clause_uniform): Likewise. | |
4789 | (c_parser_omp_for_loop): Likewise. | |
4790 | (c_parser_cilk_clause_vectorlength): Likewise. | |
4791 | (c_parser_cilk_clause_linear): Likewise. | |
4792 | (c_parser_transaction_expression): Likewise. | |
4793 | * c-parser.h (c_parser_require): Add param matching_location with | |
4794 | default UNKNOWN_LOCATION. | |
4795 | (c_parser_error): Convert return type from void to bool. | |
4796 | (c_parser_skip_until_found): Add param matching_location with | |
4797 | default UNKNOWN_LOCATION. | |
4798 | ||
30af3a2b MP |
4799 | 2017-08-09 Marek Polacek <polacek@redhat.com> |
4800 | ||
4801 | * c-decl.c (build_enumerator): Use true/false instead of 1/0. | |
4802 | * c-tree.h (build_external_ref): Update declaration. | |
4803 | * c-typeck.c (build_array_ref): Use true/false instead of 1/0. | |
4804 | (build_external_ref): Change the type of a parameter to bool. | |
4805 | (parser_build_binary_op): Use true/false instead of 1/0. | |
4806 | (pointer_diff): Likewise. | |
4807 | (build_modify_expr): Likewise. | |
4808 | (set_designator): Change the type of a parameter to bool. | |
4809 | (set_init_index): Use true/false instead of 1/0. | |
4810 | (set_init_label): Likewise. | |
4811 | (output_init_element): Change the type of a parameter to bool. | |
4812 | (output_pending_init_elements): Use true/false instead of 1/0. | |
4813 | (process_init_element): Likewise. | |
4814 | (build_binary_op): Change the type of a parameter to bool. | |
4815 | ||
296c53ac MP |
4816 | 2017-08-09 Marek Polacek <polacek@redhat.com> |
4817 | ||
4818 | PR c/81233 | |
4819 | * c-typeck.c (pedwarn_init): Make the function take a variable list. | |
4820 | Call emit_diagnostic_valist instead of pedwarn. | |
4821 | (convert_for_assignment): Unroll the PEDWARN_FOR_ASSIGNMENT macro. | |
4822 | Print the relevant types in diagnostics. | |
4823 | ||
a32c8316 MP |
4824 | 2017-08-09 Marek Polacek <polacek@redhat.com> |
4825 | ||
4826 | PR c/81417 | |
4827 | * c-array-notation.c (fix_builtin_array_notation_fn): Update calls to | |
ab20d992 | 4828 | build_conditional_expr. |
a32c8316 MP |
4829 | * c-parser.c (c_parser_conditional_expression): Create locations for |
4830 | EXP1 and EXP2 from their source ranges. Pass the locations down to | |
4831 | build_conditional_expr. | |
4832 | * c-tree.h (build_conditional_expr): Update declaration. | |
4833 | * c-typeck.c (build_conditional_expr): Add location_t parameters. | |
4834 | For -Wsign-compare, also print the types. | |
4835 | ||
314e6352 ML |
4836 | 2017-08-08 Martin Liska <mliska@suse.cz> |
4837 | ||
4838 | * c-convert.c: Include header files. | |
4839 | * c-typeck.c: Likewise. | |
4840 | ||
577eec56 ML |
4841 | 2017-08-07 Martin Liska <mliska@suse.cz> |
4842 | ||
4843 | * c-parser.c (c_parser_attributes): Canonicalize name of an | |
4844 | attribute. | |
4845 | ||
f7b6353a MP |
4846 | 2017-08-02 Marek Polacek <polacek@redhat.com> |
4847 | ||
4848 | PR c/81289 | |
4849 | * c-parser.c (c_parser_unary_expression): Use set_error. | |
4850 | ||
8a6eab34 MP |
4851 | PR c/81448 |
4852 | PR c/81306 | |
4853 | * c-warn.c (warn_for_multistatement_macros): Prevent bogus | |
4854 | warnings. Avoid walking MACRO_MAP_LOCATIONS. | |
4855 | ||
ab20d992 | 4856 | 2017-07-31 Jan Hubicka <hubicka@ucw.cz> |
7fef86d3 JH |
4857 | Martin Liska <mliska@suse.cz> |
4858 | ||
4859 | * c-typeck.c (c_finish_goto_label): Build gimple predict | |
f7b6353a | 4860 | statement. |
7fef86d3 | 4861 | |
f34ebeb2 ML |
4862 | 2017-07-31 Martin Liska <mliska@suse.cz> |
4863 | ||
4864 | PR sanitize/81530 | |
4865 | * c-convert.c (convert): Guard condition with flag_sanitize_p | |
4866 | also with current_function_decl non-null equality. | |
4867 | * c-decl.c (grokdeclarator): Likewise. | |
4868 | * c-typeck.c (build_binary_op): Likewise. | |
4869 | ||
8595f67b MP |
4870 | 2017-07-25 Marek Polacek <polacek@redhat.com> |
4871 | ||
4872 | * c-decl.c (grokfield): Remove local variable. | |
4873 | ||
d49718d6 MP |
4874 | 2017-07-25 Marek Polacek <polacek@redhat.com> |
4875 | ||
4876 | PR c/81364 | |
4877 | * c-parser.c (c_parser_else_body): Don't warn about multistatement | |
4878 | macro expansion if the body is in { }. | |
4879 | (c_parser_while_statement): Likewise. | |
4880 | (c_parser_for_statement): Likewise. | |
4881 | ||
ff22eb12 NS |
4882 | 2017-07-18 Nathan Sidwell <nathan@acm.org> |
4883 | ||
4884 | * c-parser.c (c_parser_array_notation): Use TYPE_{MIN,MAX}_VALUE. | |
4885 | ||
eea77d1f DM |
4886 | 2017-07-14 David Malcolm <dmalcolm@redhat.com> |
4887 | ||
4888 | * c-decl.c (implicitly_declare): When suggesting a missing | |
4889 | #include, provide a fix-it hint. | |
4890 | ||
b6f43128 DM |
4891 | 2017-07-06 David Malcolm <dmalcolm@redhat.com> |
4892 | ||
4893 | * c-lang.c (selftest::run_c_tests): Move body to c_family_tests, | |
4894 | and call that instead. | |
4895 | * c-tree.h (selftest::run_c_tests): New decl. | |
4896 | ||
3e2becc4 MP |
4897 | 2017-06-26 Marek Polacek <polacek@redhat.com> |
4898 | ||
4899 | PR c/80116 | |
4900 | * c-parser.c (c_parser_if_body): Set the location of the | |
4901 | body of the conditional after parsing all the labels. Call | |
4902 | warn_for_multistatement_macros. | |
4903 | (c_parser_else_body): Likewise. | |
4904 | (c_parser_switch_statement): Likewise. | |
4905 | (c_parser_while_statement): Likewise. | |
4906 | (c_parser_for_statement): Likewise. | |
4907 | (c_parser_statement): Add a default argument. Save the location | |
4908 | after labels have been parsed. | |
4909 | (c_parser_c99_block_statement): Likewise. | |
4910 | ||
343ae898 RB |
4911 | 2017-06-19 Richard Biener <rguenther@suse.de> |
4912 | ||
4913 | * gimple-parser.c (c_parser_gimple_postfix_expression): Handle | |
4914 | negated _Literals to parse _Literal (int) -1. | |
4915 | ||
45b2222a ML |
4916 | 2017-06-13 Martin Liska <mliska@suse.cz> |
4917 | ||
4918 | PR sanitize/78204 | |
4919 | * c-convert.c (convert): Use sanitize_flags_p. | |
4920 | * c-decl.c (grokdeclarator): Likewise. | |
4921 | * c-typeck.c (convert_for_assignment): Likewise. | |
4922 | (c_finish_return): Likewise. | |
4923 | (build_binary_op): Likewise. | |
4924 | ||
8ab7005b JJ |
4925 | 2017-06-08 Jakub Jelinek <jakub@redhat.com> |
4926 | ||
4927 | PR c/81006 | |
4928 | * c-typeck.c (handle_omp_array_sections_1): Convert TYPE_MAX_VALUE | |
4929 | to sizetype before size_binop. | |
4930 | ||
363dc72c JJ |
4931 | 2017-06-07 Jakub Jelinek <jakub@redhat.com> |
4932 | ||
4933 | * gimple-parser.c (c_parser_parse_gimple_body): Use TDI_gimple instead | |
4934 | of TDI_generic. | |
4935 | ||
dc949728 MP |
4936 | 2017-06-06 Marek Polacek <polacek@redhat.com> |
4937 | ||
4938 | PR c/79983 | |
4939 | * c-decl.c (start_struct): Use the location of TYPE_STUB_DECL of | |
4940 | ref. | |
4941 | (start_enum): Use the location of TYPE_STUB_DECL of enumtype. | |
4942 | ||
40ffd95f BE |
4943 | 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de> |
4944 | ||
4945 | * c-parser.c (c_parser_binary_expression): Implement the | |
4946 | -Wsizeof_pointer_div warning. | |
4947 | (c_parser_postfix_expression): Allow SIZEOF_EXPR as expr.original_code | |
4948 | from a parenthesized expression. | |
4949 | (c_parser_expr_list): Use c_last_sizeof_loc. | |
4950 | * c-tree.h (c_last_sizeof_loc): New external. | |
4951 | * c-typeck.c (c_last_sizeof_loc): New variable. | |
4952 | (c_expr_sizeof_expr, c_expr_sizeof_type): Assign c_last_sizeof_loc. | |
4953 | ||
9fc5e7a4 MM |
4954 | 2017-05-31 Mikhail Maltsev <maltsevm@gmail.com> |
4955 | ||
4956 | PR testsuite/80580 | |
4957 | * gimple-parser.c (c_parser_gimple_if_stmt): Check for empty labels. | |
4958 | ||
f012c8ef DM |
4959 | 2017-05-30 David Malcolm <dmalcolm@redhat.com> |
4960 | ||
4961 | * c-objc-common.c (c_tree_printer): Gain bool and const char ** | |
4962 | parameters. | |
4963 | ||
3cd211af MS |
4964 | 2017-05-24 Martin Sebor <msebor@redhat.com> |
4965 | ||
4966 | PR c/80731 | |
4967 | * c-fold.c (c_fully_fold_internal): Adjust. | |
4968 | * c-typeck.c (parser_build_unary_op): Adjust. | |
4969 | ||
fd71a9a2 TS |
4970 | 2017-05-23 Thomas Schwinge <thomas@codesourcery.com> |
4971 | ||
4972 | * c-parser.c (OACC_KERNELS_CLAUSE_MASK): Add | |
4973 | "PRAGMA_OACC_CLAUSE_NUM_GANGS", "PRAGMA_OACC_CLAUSE_NUM_WORKERS", | |
4974 | "VECTOR_LENGTH". | |
4975 | ||
92fa0f9e MP |
4976 | 2017-05-23 Marek Polacek <polacek@redhat.com> |
4977 | ||
4978 | * c-parser.c (c_parser_compound_statement_nostart): Remove redundant | |
4979 | quotes. | |
4980 | ||
d11c168a JJ |
4981 | 2017-05-22 Jakub Jelinek <jakub@redhat.com> |
4982 | ||
4983 | * c-fold.c (c_fully_fold_internal): Save the c_fully_fold_internal | |
4984 | result for SAVE_EXPR operand and set SAVE_EXPR_FOLDED_P even if | |
4985 | it returned invariant. Call tree_invariant_p unconditionally | |
4986 | afterwards to decide whether to return expr or op0. | |
4987 | ||
58aca9d9 NS |
4988 | 2017-05-22 Nathan Sidwell <nathan@acm.org> |
4989 | ||
4990 | * c-decl.c (c_parse_final_cleanups): Drop TDI_tu handling. | |
4991 | ||
7fd549d2 TS |
4992 | 2017-05-19 Thomas Schwinge <thomas@codesourcery.com> |
4993 | ||
4994 | * c-parser.c (c_parser_omp_clause_default): Handle | |
4995 | "OMP_CLAUSE_DEFAULT_PRESENT". | |
4996 | ||
6ecd2339 BE |
4997 | 2017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de> |
4998 | ||
4999 | * config-lang.in (gtfiles): Add c-family/c-format.c. | |
5000 | ||
8a57ecff NS |
5001 | 2017-05-18 Nathan Sidwell <nathan@acm.org> |
5002 | ||
5003 | * c-decl.c (pushdecl_top_level): Delete unused function. | |
5004 | ||
6574d78e MP |
5005 | 2017-05-18 Marek Polacek <polacek@redhat.com> |
5006 | ||
5007 | * c-decl.c (match_builtin_function_types): Use NULL_TREE instead of 0. | |
5008 | (check_earlier_gotos): Likewise. | |
5009 | (define_label): Likewise. | |
5010 | (pending_xref_error): Likewise. | |
5011 | (smallest_type_quals_location): Likewise. | |
5012 | (grokdeclarator): Likewise. | |
5013 | (grokparms): Likewise. | |
5014 | (identifier_global_value): Likewise. | |
5015 | * c-typeck.c (set_nonincremental_init_from_string): Likewise. | |
5016 | (find_init_member): Likewise. | |
5017 | ||
e3455240 MP |
5018 | 2017-05-18 Marek Polacek <polacek@redhat.com> |
5019 | ||
5020 | * c-decl.c (start_decl): Use false/true instead of 0/1. | |
5021 | (grokdeclarator): Likewise. | |
5022 | (finish_struct): Likewise. | |
5023 | (start_function): Change the return type to bool. Use false/true | |
5024 | instead of 0/1. | |
5025 | (declspecs_add_qual): Use UNKNOWN_LOCATION instead of 0. | |
5026 | * c-tree.h (start_function): Update. | |
5027 | * c-typeck.c (same_translation_unit_p): Change the return type to bool. | |
5028 | (set_designator): Change the return type to bool. Use false/true | |
5029 | instead of 0/1. | |
5030 | ||
3fa8871b MP |
5031 | 2017-05-17 Marek Polacek <polacek@redhat.com> |
5032 | ||
5033 | * c-decl.c: Use NULL_TREE instead of 0 where appropriate. | |
5034 | * c-typeck.c: Likewise. | |
5035 | ||
142473df MP |
5036 | 2017-05-17 Marek Polacek <polacek@redhat.com> |
5037 | ||
5038 | PR sanitizer/80659 | |
5039 | * c-decl.c (build_compound_literal): Set DECL_ARTIFICIAL and | |
5040 | DECL_IGNORED_P even for non-static compound literals. | |
5041 | ||
1a817418 ML |
5042 | 2017-05-17 Martin Liska <mliska@suse.cz> |
5043 | ||
5044 | * c-decl.c (c_parse_final_cleanups): Introduce dump_flags_t type and | |
5045 | use it instead of int type. | |
5046 | ||
b2fa0a8b MP |
5047 | 2017-05-17 Marek Polacek <polacek@redhat.com> |
5048 | ||
5049 | * c-convert.c (convert): Replace c_save_expr with save_expr. Don't | |
5050 | call c_fully_fold. | |
5051 | (convert) <case COMPLEX_TYPE>: Remove special handling of COMPLEX_TYPEs. | |
ab20d992 | 5052 | * c-decl.c (grokdeclarator): Replace c_save_expr with save_expr. |
b2fa0a8b MP |
5053 | * c-fold.c (c_fully_fold_internal): Handle SAVE_EXPR. |
5054 | * c-parser.c (c_parser_declaration_or_fndef): Replace c_save_expr with | |
5055 | save_expr. | |
5056 | (c_parser_conditional_expression): Likewise. | |
5057 | * c-tree.h (SAVE_EXPR_FOLDED_P): Define. | |
5058 | * c-typeck.c (build_modify_expr): Replace c_save_expr with save_expr. | |
5059 | (process_init_element): Likewise. | |
5060 | (build_binary_op): Likewise. | |
5061 | (handle_omp_array_sections_1): Likewise. | |
5062 | ||
1e47f02b TS |
5063 | 2017-05-12 Thomas Schwinge <thomas@codesourcery.com> |
5064 | ||
5065 | * c-parser.c (c_parser_omp_clause_num_gangs) | |
5066 | (c_parser_omp_clause_num_workers) | |
5067 | (c_parser_omp_clause_vector_length): Merge functions into... | |
5068 | (c_parser_oacc_single_int_clause): ... this new function. Adjust | |
5069 | all users. | |
5070 | ||
c24e924f NS |
5071 | 2017-05-11 Nathan Sidwell <nathan@acm.org> |
5072 | ||
5073 | * gimple-parser.c: Don't #include tree-dump.h. | |
5074 | ||
c587104e MM |
5075 | 2017-05-11 Mikhail Maltsev <maltsevm@gmail.com> |
5076 | ||
5077 | PR testsuite/80580 | |
5078 | * gimple-parser.c (c_parser_parse_ssa_name): Validate SSA name base. | |
5079 | ||
67ac9a9d MM |
5080 | 2017-05-11 Mikhail Maltsev <maltsevm@gmail.com> |
5081 | ||
5082 | PR testsuite/80580 | |
5083 | * gimple-parser.c (c_parser_gimple_postfix_expression): Handle | |
5084 | incorrect __MEM syntax. | |
5085 | ||
ac4eb40f MM |
5086 | 2017-05-11 Mikhail Maltsev <maltsevm@gmail.com> |
5087 | ||
5088 | PR testsuite/80580 | |
5089 | * gimple-parser.c (c_parser_gimple_unary_expression): Check argument | |
5090 | type of unary '*'. | |
5091 | ||
641da50a NS |
5092 | 2017-05-09 Nathan Sidwell <nathan@acm.org> |
5093 | ||
5094 | * c-tree.h (pushdecl): Declare. | |
5095 | ||
56d35585 DM |
5096 | 2017-05-05 David Malcolm <dmalcolm@redhat.com> |
5097 | ||
5098 | * c-decl.c (warn_defaults_to): Replace report_diagnostic | |
5099 | with diagnostic_report_diagnostic. | |
5100 | * c-errors.c (pedwarn_c99): Likewise. | |
5101 | (pedwarn_c90): Likewise. | |
5102 | ||
815d9cc6 XR |
5103 | 2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn> |
5104 | ||
92a285c1 | 5105 | PR c++/80038 |
815d9cc6 XR |
5106 | * c-gimplify.c (c_gimplify_expr): Remove calls to |
5107 | cilk_gimplifY_call_params_in_spawned_fn. | |
5108 | ||
1c4ea66f DM |
5109 | 2017-04-25 David Malcolm <dmalcolm@redhat.com> |
5110 | ||
5111 | * c-parser.c (c_parser_struct_or_union_specifier): Add fix-it | |
5112 | hint for removing extra semicolon. | |
5113 | ||
666f7903 JJ |
5114 | 2017-04-21 Jakub Jelinek <jakub@redhat.com> |
5115 | ||
5116 | PR c/80468 | |
5117 | * c-decl.c (finish_declspecs) <case cts_int_n>: If int_n_idx is not | |
5118 | enabled, set specs->type to integer_type_node. | |
5119 | ||
5764ee3c JW |
5120 | 2017-04-03 Jonathan Wakely <jwakely@redhat.com> |
5121 | ||
5122 | * c-array-notation.c: Fix typo in comment. | |
5123 | ||
10fa8dfb MP |
5124 | 2017-03-29 Marek Polacek <polacek@redhat.com> |
5125 | ||
5126 | PR c/79730 | |
5127 | * c-decl.c (finish_decl): Check VAR_P. | |
5128 | ||
a9e4a1a5 JJ |
5129 | 2017-03-27 Jakub Jelinek <jakub@redhat.com> |
5130 | ||
5131 | PR middle-end/80162 | |
5132 | * c-tree.h (c_mark_addressable): Add array_ref_p argument. | |
5133 | * c-typeck.c (c_mark_addressable): Likewise. Look through | |
5134 | VIEW_CONVERT_EXPR unless array_ref_p and VCE is from VECTOR_TYPE | |
5135 | to ARRAY_TYPE. | |
5136 | (build_array_ref): Pass true as array_ref_p to c_mark_addressable. | |
5137 | ||
ee3ff394 MP |
5138 | 2017-03-23 Marek Polacek <polacek@redhat.com> |
5139 | ||
5140 | * c-tree.h: Remove a C_RID_YYCODE reference. | |
5141 | ||
4d1b8e70 JJ |
5142 | 2017-03-21 Jakub Jelinek <jakub@redhat.com> |
5143 | ||
5144 | PR c/80097 | |
5145 | * c-typeck.c (build_binary_op): Add EXCESS_PRECISION_EXPR only around | |
5146 | optional COMPOUND_EXPR with ubsan instrumentation. | |
5147 | ||
31dc71a8 MP |
5148 | 2017-03-17 Marek Polacek <polacek@redhat.com> |
5149 | ||
5150 | * c-parser.c: Add C11 references. | |
5151 | ||
d579c385 MP |
5152 | 2017-03-15 Marek Polacek <polacek@redhat.com> |
5153 | ||
5154 | * c-parser.c (c_parser_enum_specifier): Remove redundant line. | |
5155 | ||
85059a38 MP |
5156 | 2017-03-11 Marek Polacek <polacek@redhat.com> |
5157 | ||
5158 | * c-decl.c (implicit_decl_warning): Add a comment. Fix formatting. | |
5159 | ||
2f6f187a DM |
5160 | 2017-03-10 David Malcolm <dmalcolm@redhat.com> |
5161 | ||
5162 | PR translation/79848 | |
5163 | * c-decl.c (declspecs_add_type): Simplify uses of "%<%s%>" to | |
5164 | "%qs". | |
5165 | * c-parser.c (c_parser_oacc_shape_clause): Likewise. | |
5166 | ||
36618428 MP |
5167 | 2017-03-09 Marek Polacek <polacek@redhat.com> |
5168 | ||
5169 | PR sanitizer/79757 | |
5170 | * c-parser.c (c_parser_declaration_or_fndef): Don't sanitize old-style | |
5171 | parameter declarations with initializers. | |
5172 | ||
01e5af5a JJ |
5173 | 2017-03-09 Jakub Jelinek <jakub@redhat.com> |
5174 | ||
5175 | PR c/79969 | |
5176 | * c-decl.c (start_enum): Adjust DECL_SOURCE_LOCATION of | |
5177 | TYPE_STUB_DECL. | |
5178 | ||
a71dbc63 JJ |
5179 | 2017-03-07 Jakub Jelinek <jakub@redhat.com> |
5180 | ||
5181 | PR c/79834 | |
5182 | * c-parser.c (c_parser_pragma): Use error_at instead of c_parser_error | |
5183 | for "may only be used in compound statements" diagnostics, change it | |
5184 | such that the same translatable string is used for all pragmas. For | |
5185 | PRAGMA_OACC_WAIT use "acc wait" rather than "acc enter data" in the | |
5186 | diagnostics. | |
5187 | (c_parser_omp_cancellation_point, c_parser_omp_target_update, | |
5188 | c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): Change | |
5189 | "may only be used in compound statements" diagnostics, such that the | |
5190 | same translatable string is used for all pragmas. | |
5191 | ||
1ff4bae6 MP |
5192 | 2017-03-04 Marek Polacek <polacek@redhat.com> |
5193 | ||
5194 | PR c/79847 | |
5195 | * c-decl.c (implicit_decl_warning): Add missing space. | |
5196 | ||
7f5a7d78 MP |
5197 | 2017-03-03 Marek Polacek <polacek@redhat.com> |
5198 | ||
5199 | PR c/79758 | |
5200 | * c-decl.c (store_parm_decls_oldstyle): Check if the element of | |
5201 | current_function_prototype_arg_types is error_mark_node. Fix | |
5202 | formatting. Use TREE_VALUE instead of TREE_TYPE. | |
5203 | ||
883c8f06 JJ |
5204 | 2017-03-03 Jakub Jelinek <jakub@redhat.com> |
5205 | ||
79c9b7a8 JJ |
5206 | PR c/79837 |
5207 | * c-parser.c (c_parser_omp_clause_reduction): Don't mention | |
5208 | %<min%> or %<max%> in the diagnostics, instead mention identifier. | |
5209 | (c_parser_omp_declare_reduction): Don't mention %<min%> in the | |
5210 | diagnostics. | |
5211 | ||
883c8f06 JJ |
5212 | PR c/79836 |
5213 | * c-parser.c (c_parser_generic_selection): Use %<_Generic%> | |
5214 | instead of %<_Generic>. | |
5215 | (c_parser_omp_ordered): Use %<depend%> instead of %<depend>. | |
5216 | (c_parser_omp_target_exit_data): Use %<release%> instead of | |
5217 | %<release>. | |
5218 | ||
324ff1a0 JJ |
5219 | 2017-02-28 Jakub Jelinek <jakub@redhat.com> |
5220 | ||
5221 | * c-parser.c (c_parser_asm_statement): Use cond ? G_("...") : G_("...") | |
5222 | instead of just cond ? "..." : "...". | |
5223 | (c_parser_oacc_enter_exit_data): Use %s and ternary operator only | |
5224 | for "enter"/"exit" keyword. | |
5225 | (c_finish_oacc_routine): Don't use %s to supply portions of the | |
5226 | message. | |
5227 | ||
4227c9ad JJ |
5228 | 2017-02-24 Jakub Jelinek <jakub@redhat.com> |
5229 | ||
5230 | PR c++/79588 | |
5231 | * c-parser.c (c_parser_postfix_expression_after_primary): Don't | |
5232 | handle -Wrestrict here. | |
5233 | * c-typeck.c (build_function_call_vec): Adjust | |
5234 | check_function_arguments caller. | |
5235 | ||
5d972e66 RB |
5236 | 2017-02-23 Richard Biener <rguenther@suse.de> |
5237 | ||
5238 | PR c/79684 | |
5239 | * gimple-parser.c (c_parser_gimple_statement): Use set_error | |
5240 | to initialize c_exprs to return. | |
5241 | (c_parser_gimple_binary_expression): Likewise. | |
5242 | (c_parser_gimple_unary_expression): Likewise. | |
5243 | (c_parser_gimple_postfix_expression): Likewise. | |
5244 | ||
61ac5ebe MP |
5245 | 2017-02-22 Marek Polacek <polacek@redhat.com> |
5246 | ||
5247 | PR c/79662 | |
5248 | * c-typeck.c (convert_arguments): Handle error_mark_node. | |
5249 | ||
41d1b0b1 PK |
5250 | 2017-02-19 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
5251 | ||
5252 | * gimple-parser.c (c_parser_gimple_postfix_expression): Check return | |
5253 | value of c_parser_parse_ssa_name against error_mark_node and emit | |
5254 | error if ssa name is anonymous and written as default definition. | |
5255 | ||
eab1f169 PK |
5256 | 2017-02-19 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
5257 | ||
5258 | * gimple-parser.c (c_parser_gimple_postfix_expression): Handle | |
5259 | FMA_EXPR. | |
5260 | ||
bcac0b4d JJ |
5261 | 2017-02-16 Jakub Jelinek <jakub@redhat.com> |
5262 | ||
5263 | PR c++/79512 | |
5264 | * c-parser.c (c_parser_omp_target): For -fopenmp-simd | |
5265 | ignore #pragma omp target even when not followed by identifier. | |
5266 | ||
1be33173 PK |
5267 | 2017-02-14 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
5268 | ||
5269 | * gimpler-parser.c (c_parser_gimple_statement): Handle ABS_EXPR. | |
5270 | (c_parser_gimple_unary_expression): Likewise. | |
5271 | ||
aa326bfb JJ |
5272 | 2017-02-13 Jakub Jelinek <jakub@redhat.com> |
5273 | ||
5274 | * c-parser.c (c_parser_oacc_declare): Add missing space in | |
5275 | diagnostics. | |
5276 | ||
8a398bc5 PK |
5277 | 2017-02-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
5278 | ||
5279 | PR c/79478 | |
5280 | * gimple-parser.c (c_parser_gimple_postfix_expression): Call | |
5281 | set_c_expr_source_range when parsing ssa-name. | |
5282 | ||
3dcde5ef | 5283 | 2017-02-10 Prasad Ghangal <prasad.ghangal@gmail.com> |
ab20d992 | 5284 | Richard Biener <rguenther@suse.de> |
3dcde5ef PG |
5285 | |
5286 | * gimple-parser.c (c_parser_gimple_binary_expression): Avoid | |
5287 | building IL when arguments are error_mark_node. | |
5288 | (c_parser_gimple_unary_expression): Likewise. | |
5289 | (c_parser_gimple_if_stmt): Likewise. | |
5290 | (c_parser_gimple_switch_stmt): Likewise. | |
5291 | (c_parser_gimple_return_stmt): Likewise. | |
5292 | (c_parser_parse_ssa_name): When name lookup fails do not build | |
5293 | an SSA name. Use undeclared rather than not declared in error | |
5294 | reporting. | |
5295 | ||
192b048b MP |
5296 | 2017-02-09 Marek Polacek <polacek@redhat.com> |
5297 | ||
5298 | PR c/79428 | |
5299 | * c-parser.c (c_parser_omp_ordered): Call c_parser_skip_to_pragma_eol | |
5300 | instead of c_parser_skip_until_found. | |
5301 | ||
56f71478 JJ |
5302 | 2017-02-09 Jakub Jelinek <jakub@redhat.com> |
5303 | ||
5304 | PR c/79431 | |
5305 | * c-parser.c (c_parser_omp_declare_target): Don't invoke | |
5306 | symtab_node::get on automatic variables. | |
5307 | ||
02889d23 CLT |
5308 | 2016-02-09 Nathan Sidwell <nathan@codesourcery.com> |
5309 | Chung-Lin Tang <cltang@codesourcery.com> | |
5310 | ||
5311 | * c-parser.c (c_parser_omp_clause_collapse): Disallow tile. | |
5312 | (c_parser_oacc_clause_tile): Disallow collapse. Fix parsing and | |
5313 | semantic checking. | |
5314 | * c-parser.c (c_parser_omp_for_loop): Accept tiling constructs. | |
5315 | ||
7af4b20d RB |
5316 | 2017-02-07 Richard Biener <rguenther@suse.de> |
5317 | ||
5318 | * gimple-parser.c (c_parser_gimple_expr_list): Simplify. | |
5319 | (c_parser_gimple_postfix_expression_after_primary): | |
5320 | Do not use c_build_function_call_vec to avoid folding and promotion. | |
5321 | Simplify. | |
5322 | ||
e5e391d6 MO |
5323 | 2017-01-25 Maxim Ostapenko <m.ostapenko@samsung.com> |
5324 | ||
5325 | PR lto/79061 | |
5326 | * c-decl.c (pop_scope): Pass main_input_filename to | |
5327 | build_translation_unit_decl. | |
5328 | ||
c2e84327 DM |
5329 | 2017-01-24 David Malcolm <dmalcolm@redhat.com> |
5330 | ||
5331 | * c-parser.c: Include "read-rtl-function.h" and | |
5332 | "run-rtl-passes.h". | |
5333 | (c_parser_declaration_or_fndef): Rename "gimple-pass-list" in | |
5334 | grammar to gimple-or-rtl-pass-list. Add rtl-function-definition | |
5335 | production. Update for renaming of field "gimple_pass" to | |
5336 | "gimple_or_rtl_pass". If __RTL was seen, call | |
5337 | c_parser_parse_rtl_body. Convert a timevar_push/pop pair | |
5338 | to an auto_timevar, to cope with early exit. | |
5339 | (c_parser_declspecs): Update RID_GIMPLE handling for renaming of | |
5340 | field "gimple_pass" to "gimple_or_rtl_pass", and for renaming of | |
5341 | c_parser_gimple_pass_list to c_parser_gimple_or_rtl_pass_list. | |
5342 | Handle RID_RTL. | |
5343 | (c_parser_parse_rtl_body): New function. | |
5344 | * c-tree.h (enum c_declspec_word): Add cdw_rtl. | |
5345 | (struct c_declspecs): Rename field "gimple_pass" to | |
5346 | "gimple_or_rtl_pass". Add field "rtl_p". | |
5347 | * gimple-parser.c (c_parser_gimple_pass_list): Rename to... | |
5348 | (c_parser_gimple_or_rtl_pass_list): ...this, updating accordingly. | |
5349 | * gimple-parser.h (c_parser_gimple_pass_list): Rename to... | |
5350 | (c_parser_gimple_or_rtl_pass_list): ...this. | |
5351 | ||
2ebd93e1 MP |
5352 | 2017-01-20 Marek Polacek <polacek@redhat.com> |
5353 | ||
5354 | PR c/64279 | |
5355 | * c-typeck.c (build_conditional_expr): Warn about duplicated branches. | |
5356 | ||
b1c95bb5 RB |
5357 | 2017-01-13 Richard Biener <rguenther@suse.de> |
5358 | ||
5359 | * gimple-parser.c (c_parser_gimple_compound_statement): Handle | |
5360 | nops. | |
5361 | ||
25329913 RB |
5362 | 2017-01-13 Richard Biener <rguenther@suse.de> |
5363 | ||
5364 | * gimple-parser.c (c_parser_gimple_postfix_expression): Parse | |
5365 | _Literal ( type-name ) number. | |
5366 | ||
6bb4ea5c RB |
5367 | 2017-01-12 Richard Biener <rguenther@suse.de> |
5368 | ||
5369 | * gimple-parser.c (c_parser_gimple_postfix_expression): Parse | |
5370 | __MEM. | |
5371 | ||
6b5b4e9c JJ |
5372 | 2017-01-11 Jakub Jelinek <jakub@redhat.com> |
5373 | ||
5374 | PR c++/72813 | |
5375 | * c-decl.c (pop_file_scope): Set flag_syntax_only to 1 after writing | |
5376 | PCH file. | |
5377 | ||
e3252775 RB |
5378 | 2017-01-11 Richard Biener <rguenther@suse.de> |
5379 | ||
5380 | PR bootstrap/79052 | |
5381 | * gimple-parser.c (c_parser_gimple_switch_stmt): Add missing | |
5382 | returns on parse errors. | |
5383 | ||
a9342885 MP |
5384 | 2017-01-04 Marek Polacek <polacek@redhat.com> |
5385 | ||
5386 | PR c++/64767 | |
5387 | * c-parser.c (c_parser_postfix_expression): Mark zero character | |
5388 | constants by setting original_type in c_expr. | |
5389 | * c-typeck.c (parser_build_binary_op): Warn when a pointer is compared | |
5390 | with a zero character constant. | |
5391 | (char_type_p): New function. | |
5392 | ||
5dd9a9d0 DM |
5393 | 2017-01-04 David Malcolm <dmalcolm@redhat.com> |
5394 | ||
5395 | * c-parser.c (c_parser_declaration_or_fndef): Create a | |
5396 | rich_location at init_loc and parse it to start_init. | |
5397 | (last_init_list_comma): New global. | |
5398 | (c_parser_braced_init): Update last_init_list_comma when parsing | |
5399 | commas. Pass it to pop_init_level. Pass location of closing | |
5400 | brace to pop_init_level. | |
5401 | (c_parser_postfix_expression_after_paren_type): Create a | |
5402 | rich_location at type_loc and parse it to start_init. | |
5403 | (c_parser_omp_declare_reduction): Likewise for loc. | |
5404 | * c-tree.h (start_init): Add rich_location * param. | |
5405 | (pop_init_level): Add location_t param. | |
5406 | * c-typeck.c (struct initializer_stack): Add field | |
5407 | "missing_brace_richloc". | |
5408 | (start_init): Add richloc param, use it to initialize | |
5409 | the stack node's missing_brace_richloc. | |
5410 | (last_init_list_comma): New decl. | |
5411 | (finish_implicit_inits): Pass last_init_list_comma to | |
5412 | pop_init_level. | |
5413 | (push_init_level): When finding missing open braces, add fix-it | |
5414 | hints to the richloc. | |
5415 | (pop_init_level): Add "insert_before" param and pass it | |
5416 | when calling pop_init_level. Add fixits about missing | |
5417 | close braces to any richloc. Use the richloc for the | |
5418 | -Wmissing-braces warning. | |
5419 | (set_designator): Pass last_init_list_comma to pop_init_level. | |
5420 | (process_init_element): Likewise. | |
5421 | ||
cbe34bb5 JJ |
5422 | 2017-01-01 Jakub Jelinek <jakub@redhat.com> |
5423 | ||
5424 | Update copyright years. | |
5425 | ||
d17680f3 JJ |
5426 | 2016-12-21 Jakub Jelinek <jakub@redhat.com> |
5427 | ||
0dba7960 JJ |
5428 | PR bootstrap/78817 |
5429 | * c-typeck.c (build_function_call_vec): If check_function_arguments | |
5430 | returns true, set TREE_NO_WARNING on CALL_EXPR. | |
5431 | ||
d17680f3 JJ |
5432 | PR c/77767 |
5433 | * c-decl.c (grokdeclarator): If *expr is non-NULL, append expression | |
5434 | to *expr instead of overwriting it. | |
5435 | ||
aa90531e RB |
5436 | 2016-12-20 Richard Biener <rguenther@suse.de> |
5437 | ||
5438 | * gimple-parser.c (c_parser_gimple_compound_statement): Improve | |
5439 | error recovery. | |
5440 | (c_parser_gimple_statement): Only build assigns for non-error | |
5441 | stmts. | |
5442 | (c_parser_gimple_postfix_expression_after): Improve error recovery. | |
5443 | ||
629b3d75 MJ |
5444 | 2016-12-14 Martin Jambor <mjambor@suse.cz> |
5445 | ||
5446 | * c-parser.c: Include omp-general.h and omp-offload.h instead of | |
5447 | omp-low.h. | |
5448 | (c_finish_oacc_routine): Adjusted call to | |
5449 | get_oacc_fn_attrib, build_oacc_routine_dims and replace_oacc_fn_attrib | |
5450 | to use their new names. | |
5451 | (c_parser_oacc_enter_exit_data): Adjusted call to find_omp_clause to | |
5452 | use its new name. | |
5453 | (c_parser_oacc_update): Likewise. | |
5454 | (c_parser_omp_simd): Likewise. | |
5455 | (c_parser_omp_target_update): Likewise. | |
5456 | * c-typeck.c: Include omp-general.h instead of omp-low.h. | |
5457 | (c_finish_omp_cancel): Adjusted call to find_omp_clause to use its new | |
5458 | name. | |
5459 | (c_finish_omp_cancellation_point): Likewise. | |
5460 | * gimple-parser.c: Do not include omp-low.h | |
5461 | ||
c5af52eb CP |
5462 | 2016-12-02 Cesar Philippidis <cesar@codesourcery.com> |
5463 | James Norris <jnorris@codesourcery.com> | |
5464 | ||
5465 | * c-parser.c (c_parser_pragma): Error when PRAGMA_OACC_{ENTER_DATA, | |
5466 | EXIT_DATA,WAIT} are not used in compound statements. | |
5467 | (c_parser_oacc_enter_exit_data): Update diagnostics. | |
5468 | ||
48330c93 BE |
5469 | 2016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de> |
5470 | ||
5471 | PR c++/71973 | |
5472 | * c-decl.c (diagnose_mismatched_decls): Use | |
5473 | OPT_Wbuiltin_declaration_mismatch here too. | |
5474 | ||
899ca90e | 5475 | 2016-11-18 Richard Sandiford <richard.sandiford@arm.com> |
48330c93 BE |
5476 | Alan Hayward <alan.hayward@arm.com> |
5477 | David Sherwood <david.sherwood@arm.com> | |
899ca90e RS |
5478 | |
5479 | * c-decl.c (merge_decls): Use SET_DECL_MODE. | |
5480 | (make_label, finish_struct): Likewise. | |
5481 | ||
1ee62b92 | 5482 | 2016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com> |
8e745a17 | 5483 | Richard Biener <rguenther@suse.de> |
22b15758 | 5484 | |
8e745a17 JJ |
5485 | * Make-lang.in (C_AND_OBJC_OBJS): Add gimple-parser.o. |
5486 | * config-lang.in (gtfiles): Add c/c-parser.h. | |
5487 | * c-tree.h (enum c_declspec_word): Add cdw_gimple. | |
5488 | (struct c_declspecs): Add gimple_pass member and gimple_p flag. | |
5489 | * c-parser.c (enum c_id_kind, struct c_token, | |
5490 | c_parser_next_token_is, c_parser_next_token_is_not, | |
5491 | c_parser_next_token_is_keyword, | |
5492 | enum c_lookahead_kind, enum c_dtr_syn, enum c_parser_prec): | |
5493 | Split out to ... | |
5494 | * c-parser.h: ... new header. | |
5495 | * c-parser.c: Include c-parser.h and gimple-parser.h. | |
1ee62b92 | 5496 | (c_parser_peek_token, c_parser_peek_2nd_token, |
8e745a17 JJ |
5497 | c_token_starts_typename, c_parser_next_token_starts_declspecs, |
5498 | c_parser_next_tokens_start_declaration, c_parser_consume_token, | |
5499 | c_parser_error, c_parser_require, c_parser_skip_until_found, | |
5500 | c_parser_declspecs, c_parser_declarator, c_parser_peek_nth_token, | |
5501 | c_parser_type_name): Export. | |
5502 | (c_parser_tokens_buf): New function. | |
5503 | (c_parser_error): Likewise. | |
5504 | (c_parser_set_error): Likewise. | |
5505 | (c_parser_declspecs): Handle RID_GIMPLE. | |
1ee62b92 PG |
5506 | (c_parser_declaration_or_fndef): Parse __GIMPLE marked body |
5507 | via c_parser_parse_gimple_body. | |
8e745a17 JJ |
5508 | * c-parser.h (c_parser_peek_token, c_parser_peek_2nd_token, |
5509 | c_token_starts_typename, c_parser_next_token_starts_declspecs, | |
5510 | c_parser_next_tokens_start_declaration, c_parser_consume_token, | |
5511 | c_parser_error, c_parser_require, c_parser_skip_until_found, | |
5512 | c_parser_declspecs, c_parser_declarator, c_parser_peek_nth_token, | |
5513 | c_parser_type_name): Declare. | |
1ee62b92 PG |
5514 | (struct c_parser): Declare forward. |
5515 | (c_parser_tokens_buf): Declare. | |
8e745a17 JJ |
5516 | (c_parser_error): Likewise. |
5517 | (c_parser_set_error): Likewise. | |
5518 | * gimple-parser.c: New file. | |
5519 | * gimple-parser.h: Likewise. | |
1ee62b92 | 5520 | |
22b15758 UB |
5521 | 2016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
5522 | ||
5523 | PR c/35503 | |
5524 | * c-parser.c (c_parser_postfix_expression_after_primary): Call | |
5525 | warn_for_restrict. | |
5526 | ||
84ff4775 LCW |
5527 | 2016-09-11 Le-Chun Wu <lcwu@google.com> |
5528 | Mark Wielaard <mjw@redhat.com> | |
5529 | ||
5530 | * c-decl.c (warn_if_shadowing): Use the warning code corresponding | |
5531 | to the given -Wshadow= variant. | |
5532 | ||
4d0cdd0c TP |
5533 | 2016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com> |
5534 | ||
5535 | * c-typeck.c: Include memmodel.h. | |
5536 | ||
1202f33e JJ |
5537 | 2016-10-13 Jakub Jelinek <jakub@redhat.com> |
5538 | ||
5539 | PR target/77957 | |
5540 | * c-objc-common.h (LANG_HOOKS_GETDECLS): Use hook_tree_void_null | |
5541 | instead of lhd_return_null_tree_v. | |
5542 | ||
8a14afd0 BS |
5543 | 2016-10-07 Bernd Schmidt <bschmidt@redhat.com> |
5544 | ||
5545 | PR c++/69733 | |
5546 | * c-decl.c (smallest_type_quals_location): New static function. | |
5547 | (grokdeclarator): Try to find the correct location for an ignored | |
5548 | qualifier. | |
5549 | ||
81fea426 MP |
5550 | 2016-09-26 Marek Polacek <polacek@redhat.com> |
5551 | ||
5552 | PR c/7652 | |
5553 | * c-decl.c (pop_scope): Add gcc_fallthrough. | |
5554 | ||
5555 | 2016-09-26 Marek Polacek <polacek@redhat.com> | |
5556 | ||
5557 | PR c/7652 | |
5558 | * c-parser.c (struct c_token): Add flags field. | |
5559 | (c_lex_one_token): Pass it to c_lex_with_flags. | |
5560 | (c_parser_declaration_or_fndef): Turn __attribute__((fallthrough)); | |
5561 | into IFN_FALLTHROUGH. | |
5562 | (c_parser_label): Set FALLTHROUGH_LABEL_P on labels. Handle | |
5563 | attribute fallthrough after a case label or default label. | |
5564 | (c_parser_statement_after_labels): Handle RID_ATTRIBUTE. | |
5565 | ||
9a2300e9 MP |
5566 | 2016-09-24 Marek Polacek <polacek@redhat.com> |
5567 | ||
5568 | PR c/77490 | |
5569 | * c-typeck.c (build_unary_op): Warn about bit not on expressions that | |
5570 | have boolean value. Warn about ++/-- on booleans. | |
5571 | ||
7de76362 JJ |
5572 | 2016-09-23 Jakub Jelinek <jakub@redhat.com> |
5573 | ||
5574 | * c-parser.c (incomplete_record_decls): Remove unnecessary | |
5575 | = vNULL initialization of file scope vec. | |
5576 | ||
5b73d2ab MP |
5577 | 2016-09-16 Marek Polacek <polacek@redhat.com> |
5578 | ||
5579 | * c-typeck.c (lvalue_p): Use true and false instead of 1 and 0. | |
5580 | ||
e51fbec3 MP |
5581 | 2016-09-14 Marek Polacek <polacek@redhat.com> |
5582 | ||
5583 | * c-array-notation.c (create_cmp_incr): Use false instead of 0. | |
5584 | (fix_array_notation_expr): Likewise. | |
5585 | * c-decl.c (finish_decl): Likewise. | |
5586 | * c-parser.c (c_parser_postfix_expression_after_primary): Likewise. | |
5587 | * c-typeck.c (array_to_pointer_conversion): Use true instead of 1. | |
5588 | (function_to_pointer_conversion): Use false instead of 0. | |
5589 | (convert_lvalue_to_rvalue): Likewise. | |
5590 | (parser_build_unary_op): Likewise. | |
5591 | (build_atomic_assign): Likewise. | |
5592 | (build_unary_op): Change nonconvert parameter type to bool, use | |
5593 | true/false instead of 1/0. | |
5594 | (build_binary_op): Use true instead of 1. | |
5595 | ||
254830ba DM |
5596 | 2016-09-13 David Malcolm <dmalcolm@redhat.com> |
5597 | ||
5598 | * c-parser.c (c_parser_declaration_or_fndef): Update for renaming | |
5599 | of add_fixit_insert to add_fixit_insert_before. | |
5600 | ||
4c13ba17 MP |
5601 | 2016-09-13 Marek Polacek <polacek@redhat.com> |
5602 | ||
5603 | * c-typeck.c (build_unary_op): Rename FLAG parameter to NOCONVERT. Use | |
5604 | it. | |
5605 | ||
54dcdb88 BE |
5606 | 2016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de> |
5607 | ||
5608 | PR c++/77496 | |
5609 | * c-parser.c (c_parser_conditional_expression): Pass the rightmost | |
5610 | COMPOUND_EXPR to warn_for_omitted_condop. | |
5611 | ||
e5106e27 DM |
5612 | 2016-09-07 David Malcolm <dmalcolm@redhat.com> |
5613 | ||
5614 | * c-lang.c (LANG_HOOKS_GET_SUBSTRING_LOCATION): Use | |
5615 | c_get_substring_location for this new langhook. | |
5616 | ||
9dc5773f JJ |
5617 | 2016-09-02 Jakub Jelinek <jakub@redhat.com> |
5618 | ||
5619 | PR c/65467 | |
5620 | * c-parser.c (c_parser_declspecs): Don't sorry about _Atomic if | |
5621 | flag_openmp. | |
5622 | (c_parser_omp_variable_list): Use convert_lvalue_to_rvalue | |
5623 | instead of mark_exp_read on low_bound/length expression. | |
5624 | (c_parser_omp_clause_num_gangs, c_parser_omp_clause_num_threads, | |
5625 | c_parser_omp_clause_num_tasks, c_parser_omp_clause_grainsize, | |
5626 | c_parser_omp_clause_priority, c_parser_omp_clause_hint, | |
5627 | c_parser_omp_clause_num_workers, c_parser_oacc_shape_clause, | |
5628 | c_parser_oacc_clause_tile, c_parser_omp_clause_schedule, | |
5629 | c_parser_omp_clause_vector_length, c_parser_omp_clause_num_teams, | |
5630 | c_parser_omp_clause_thread_limit, c_parser_omp_clause_aligned, | |
5631 | c_parser_omp_clause_linear, c_parser_omp_clause_safelen, | |
5632 | c_parser_omp_clause_simdlen, c_parser_omp_clause_device, | |
5633 | c_parser_omp_clause_dist_schedule): Use convert_lvalue_to_rvalue | |
5634 | instead of mark_expr_read. | |
5635 | (c_parser_omp_declare_reduction): Reject _Atomic qualified types. | |
5636 | * c-objc-common.h (LANG_HOOKS_OMP_CLAUSE_COPY_CTOR, | |
5637 | LANG_HOOKS_OMP_CLAUSE_ASSIGN_OP): Redefine. | |
5638 | * c-tree.h (c_omp_clause_copy_ctor): New prototype. | |
5639 | * c-typeck.c (handle_omp_array_sections_1): Diagnose _Atomic qualified | |
5640 | array section bases outside of depend clause, for depend clause | |
5641 | use convert_lvalue_to_rvalue on the base. | |
5642 | (c_finish_omp_clauses): Reject _Atomic qualified vars in reduction, | |
5643 | linear, aligned, map, to and from clauses. | |
5644 | (c_omp_clause_copy_ctor): New function. | |
5645 | ||
295844f6 MP |
5646 | 2016-09-01 Marek Polacek <polacek@redhat.com> |
5647 | ||
5648 | PR c/7652 | |
5649 | * c-typeck.c (composite_type): Add FALLTHRU comment. | |
5650 | ||
089af25c DM |
5651 | 2016-08-31 David Malcolm <dmalcolm@redhat.com> |
5652 | ||
5653 | * c-parser.c (c_parser_declaration_or_fndef): Add trailing space | |
5654 | to the insertion fixits for "struct", "union", and "enum". | |
5655 | ||
f9087798 DM |
5656 | 2016-08-30 David Malcolm <dmalcolm@redhat.com> |
5657 | ||
5658 | * c-decl.c (implicit_decl_warning): Use add_fixit_replace | |
5659 | rather than add_fixit_misspelled_id. | |
5660 | (undeclared_variable): Likewise. | |
5661 | * c-parser.c (c_parser_declaration_or_fndef): Likewise. Remove | |
5662 | now-redundant "here" params from add_fixit_insert method calls. | |
5663 | (c_parser_parameter_declaration): Likewise. | |
5664 | * c-typeck.c (build_component_ref): Remove now-redundant range | |
5665 | param from add_fixit_replace method calls. | |
5666 | ||
ebef225f MP |
5667 | 2016-08-25 Marek Polacek <polacek@redhat.com> |
5668 | ||
5669 | * c-typeck.c (parser_build_binary_op): Pass LHS to | |
5670 | warn_logical_not_parentheses. | |
5671 | ||
fe377a48 MP |
5672 | 2016-08-25 Marek Polacek <polacek@redhat.com> |
5673 | ||
5674 | PR c/77323 | |
5675 | * c-decl.c (declspecs_add_type): Set typespec_word even when __intN | |
5676 | or _FloatN or _FloatNx is not supported. | |
5677 | (finish_declspecs): Set type to integer_type_node when _FloatN or | |
5678 | _FloatNx is not supported. | |
5679 | ||
c65699ef JM |
5680 | 2016-08-19 Joseph Myers <joseph@codesourcery.com> |
5681 | ||
5682 | PR c/32187 | |
5683 | * c-tree.h (cts_floatn_nx): New enum c_typespec_keyword value. | |
5684 | (struct c_declspecs): Add field floatn_nx_idx. | |
5685 | * c-decl.c (declspecs_add_type, finish_declspecs): Handle _FloatN | |
5686 | and _FloatNx type specifiers. | |
5687 | * c-parser.c (c_keyword_starts_typename, c_token_starts_declspecs) | |
5688 | (c_parser_declspecs, c_parser_attribute_any_word) | |
5689 | (c_parser_objc_selector): Use CASE_RID_FLOATN_NX. | |
5690 | * c-typeck.c (c_common_type): Handle _FloatN and _FloatNx types. | |
5691 | (convert_arguments): Avoid promoting _FloatN and _FloatNx types | |
5692 | narrower than double. | |
5693 | ||
2f1364c2 JJ |
5694 | 2016-08-12 Jakub Jelinek <jakub@redhat.com> |
5695 | Martin Liska <mliska@suse.cz> | |
5696 | ||
5697 | PR c/67410 | |
5698 | * c-typeck.c (set_nonincremental_init_from_string): Use / instead of | |
5699 | % to determine val element to change. Assert that | |
5700 | wchar_bytes * charwidth fits into val array. | |
5701 | ||
191816a3 MP |
5702 | 2016-08-12 Marek Polacek <polacek@redhat.com> |
5703 | ||
5704 | PR c/7652 | |
5705 | * c-parser.c (c_parser_external_declaration): Add FALLTHRU. | |
5706 | (c_parser_postfix_expression): Likewise. | |
5707 | * c-typeck.c (build_unary_op): Adjust fall through comment. | |
5708 | (c_mark_addressable): Likewise. | |
5709 | ||
b95a64bb JJ |
5710 | 2016-08-11 Jakub Jelinek <jakub@redhat.com> |
5711 | ||
5712 | PR c/72816 | |
5713 | * c-decl.c (grokdeclarator): When adding TYPE_DOMAIN for flexible | |
5714 | array member through typedef, for orig_qual_indirect == 0 clear | |
5715 | orig_qual_type. | |
5716 | ||
895aa8e1 DM |
5717 | 2016-08-08 David Malcolm <dmalcolm@redhat.com> |
5718 | ||
5719 | PR c/64955 | |
5720 | * c-lang.c (LANG_HOOKS_RUN_LANG_SELFTESTS): If CHECKING_P, wire | |
5721 | this up to selftest::run_c_tests. | |
5722 | (selftest::run_c_tests): New function. | |
5723 | ||
0b212d8c TS |
5724 | 2016-08-04 Thomas Schwinge <thomas@codesourcery.com> |
5725 | ||
ae9281fc TS |
5726 | * c-parser.c (struct oacc_routine_data): Add error_seen and |
5727 | fndecl_seen members. | |
5728 | (c_finish_oacc_routine): Use these. | |
5729 | (c_parser_declaration_or_fndef): Adjust. | |
5730 | (c_parser_oacc_routine): Likewise. Support more C language | |
5731 | constructs, and improve diagnostics. Move pragma context | |
5732 | checking... | |
5733 | (c_parser_pragma): ... here. | |
5734 | ||
0b212d8c TS |
5735 | * c-parser.c (struct oacc_routine_data): New. |
5736 | (c_parser_declaration_or_fndef, c_parser_oacc_routine): Use it. | |
5737 | Simplify code. | |
5738 | (c_finish_oacc_routine): Likewise. Don't attach clauses to "omp | |
5739 | declare target" attribute. | |
5740 | ||
76e2c821 JB |
5741 | 2016-08-01 Jan Beulich <jbeulich@suse.com> |
5742 | ||
5743 | * c-fold.c (c_fully_fold_internal): Also emit shift count | |
5744 | warnings for vector types. | |
5745 | * c-typeck.c (build_binary_op): Likewise. | |
5746 | ||
f618a472 MP |
5747 | 2016-07-29 Marek Polacek <polacek@redhat.com> |
5748 | ||
5749 | PR c/71742 | |
5750 | * c-decl.c (finish_struct): Rephrase an error message. | |
5751 | ||
efd0786f MP |
5752 | PR c/71853 |
5753 | * c-parser.c (c_parser_switch_statement): Initialize ce.original_type | |
5754 | to error node for invalid code. | |
5755 | ||
e00dceaf MP |
5756 | PR c/71573 |
5757 | * c-decl.c (implicitly_declare): Return decl early not only for | |
5758 | error_mark_nodes, but for anything that is not a FUNCTION_DECL. | |
5759 | ||
673a107a JJ |
5760 | 2016-07-29 Jakub Jelinek <jakub@redhat.com> |
5761 | ||
5762 | PR c/71969 | |
5763 | * c-decl.c (finish_function): Only set DECL_DISREGARD_INLINE_LIMITS | |
5764 | on GNU extern inline functions. | |
5765 | ||
a5b5c8b6 MP |
5766 | 2016-07-29 Marek Polacek <polacek@redhat.com> |
5767 | ||
5768 | PR c/71583 | |
5769 | * c-parser.c (c_parser_postfix_expression_after_paren_type): Also | |
5770 | check expr.value. | |
5771 | ||
e3fe09c1 UB |
5772 | 2016-07-22 Uros Bizjak <ubizjak@gmail.com> |
5773 | ||
5774 | * c-typeck.c: Use HOST_WIDE_INT_1 instead of (HOST_WIDE_INT) 1, | |
5775 | ||
7c8f7eaa DM |
5776 | 2016-07-20 David Malcolm <dmalcolm@redhat.com> |
5777 | ||
5778 | * c-decl.c (struct edit_distance_traits<cpp_hashnode *>): Move to | |
5779 | spellcheck-tree.h | |
5780 | (best_macro_match): Likewise, converting from a typedef to a | |
5781 | subclass. | |
5782 | (find_closest_macro_cpp_cb): Move to spellcheck-tree.c. | |
5783 | (lookup_name_fuzzy): Update for change of best_macro_match to a | |
5784 | subclass with a ctor that calls cpp_forall_identifiers. | |
5785 | ||
de6a69ee DM |
5786 | 2016-07-20 David Malcolm <dmalcolm@redhat.com> |
5787 | ||
5788 | * c-decl.c (implicit_decl_warning): Update for conversion of | |
5789 | return type of lookup_name_fuzzy to const char *. | |
5790 | (undeclared_variable): Likewise. | |
5791 | (lookup_name_fuzzy): Convert return type from tree to | |
5792 | const char *. | |
5793 | * c-parser.c (c_parser_declaration_or_fndef): Update for | |
5794 | conversion of return type of lookup_name_fuzzy to const char *. | |
5795 | (c_parser_parameter_declaration): Likewise. | |
5796 | ||
b1c9c068 CP |
5797 | 2016-07-15 Cesar Philippidis <cesar@codesourcery.com> |
5798 | ||
5799 | * c-parser.c (c_parser_oacc_declare): Don't scan for | |
5800 | GOMP_MAP_POINTER. | |
5801 | * c-typeck.c (handle_omp_array_sections): Mark data clauses with | |
5802 | GOMP_MAP_FORCE_{PRESENT,TO,FROM,TOFROM} as potentially having | |
5803 | zero-length subarrays. | |
5804 | ||
ddbbcb19 JJ |
5805 | 2016-07-15 Jakub Jelinek <jakub@redhat.com> |
5806 | ||
5807 | PR c/71858 | |
5808 | * c-decl.c (implicit_decl_warning): Use FUZZY_LOOKUP_FUNCTION_NAME | |
5809 | instead of FUZZY_LOOKUP_NAME. | |
5810 | (lookup_name_fuzzy): For FUZZY_LOOKUP_FUNCTION_NAME consider | |
5811 | FUNCTION_DECLs, {VAR,PARM}_DECLs function pointers and macros. | |
5812 | ||
dd36b877 JJ |
5813 | 2016-07-14 Jakub Jelinek <jakub@redhat.com> |
5814 | ||
5815 | PR c/71858 | |
5816 | * c-decl.c (lookup_name_fuzzy): Ignore binding->invisible. | |
5817 | ||
8c681247 TS |
5818 | 2016-07-12 Trevor Saunders <tbsaunde+gcc@tbsaunde.org> |
5819 | ||
5820 | * c-parser.c (c_parser_generic_selection): Make type of variable | |
5821 | auto_vec. | |
5822 | (c_parser_omp_declare_simd): Likewise. | |
5823 | ||
bf4fa671 TS |
5824 | 2016-07-12 Trevor Saunders <tbsaunde+gcc@tbsaunde.org> |
5825 | ||
5826 | * c-decl.c (struct c_struct_parse_info): Change member types | |
5827 | from vec to auto_vec. | |
5828 | (start_struct): Adjust. | |
5829 | (finish_struct): Likewise. | |
5830 | ||
557e8c49 JJ |
5831 | 2016-07-02 Jakub Jelinek <jakub@redhat.com> |
5832 | ||
5833 | PR c/71719 | |
5834 | * c-typeck.c (mark_exp_read): Handle VIEW_CONVERT_EXPR. | |
5835 | ||
54d19c3b TS |
5836 | 2016-06-29 Thomas Schwinge <thomas@codesourcery.com> |
5837 | ||
5838 | * c-parser.c (c_parser_pragma) <PRAGMA_OMP_CANCELLATION_POINT>: | |
5839 | Move pragma context checking into... | |
5840 | (c_parser_omp_cancellation_point): ... here, and improve | |
5841 | diagnostic messages. | |
5842 | * c-typeck.c (c_finish_omp_cancel) | |
5843 | (c_finish_omp_cancellation_point): Improve diagnostic messages. | |
5844 | ||
152ef731 JJ |
5845 | 2016-06-29 Jakub Jelinek <jakub@redhat.com> |
5846 | ||
5847 | PR c/71685 | |
5848 | * c-typeck.c (c_build_qualified_type): Don't clear | |
5849 | C_TYPE_INCOMPLETE_VARS for the main variant. | |
5850 | ||
5851 | 2016-06-28 Martin Sebor <msebor@redhat.com> | |
4378d117 MS |
5852 | |
5853 | PR c/71552 | |
5854 | * c-typeck.c (output_init_element): Diagnose incompatible types | |
5855 | before non-constant initializers. | |
5856 | ||
e9ac1f86 JJ |
5857 | 2016-06-28 Jakub Jelinek <jakub@redhat.com> |
5858 | ||
5859 | * Make-lang.in: Don't cat ../stage_current if it does not exist. | |
5860 | ||
277d7ee0 AK |
5861 | 2016-06-23 Andi Kleen <ak@linux.intel.com> |
5862 | ||
5863 | * Make-lang.in: Add support for autofdo. | |
5864 | ||
1a4f11c8 DM |
5865 | 2016-06-22 David Malcolm <dmalcolm@redhat.com> |
5866 | ||
5867 | PR c/70339 | |
5868 | * c-decl.c: Include spellcheck-tree.h and gcc-rich-location.h. | |
5869 | (implicit_decl_warning): When issuing warnings for implicit | |
5870 | declarations, attempt to provide a suggestion via | |
5871 | lookup_name_fuzzy. | |
5872 | (undeclared_variable): Likewise when issuing errors. | |
5873 | (lookup_name_in_scope): Likewise. | |
5874 | (struct edit_distance_traits<cpp_hashnode *>): New struct. | |
5875 | (best_macro_match): New typedef. | |
5876 | (find_closest_macro_cpp_cb): New function. | |
5877 | (lookup_name_fuzzy): New function. | |
5878 | * c-parser.c: Include gcc-rich-location.h. | |
5879 | (c_token_starts_typename): Split out case CPP_KEYWORD into... | |
5880 | (c_keyword_starts_typename): ...this new function. | |
5881 | (c_parser_declaration_or_fndef): When issuing errors about | |
5882 | missing "struct" etc, add a fixit. For other kinds of errors, | |
5883 | attempt to provide a suggestion via lookup_name_fuzzy. | |
5884 | (c_parser_parms_declarator): When looking ahead to detect typos in | |
5885 | type names, also reject CPP_KEYWORD. | |
5886 | (c_parser_parameter_declaration): When issuing errors about | |
5887 | unknown type names, attempt to provide a suggestion via | |
5888 | lookup_name_fuzzy. | |
5889 | * c-tree.h (c_keyword_starts_typename): New prototype. | |
5890 | ||
5a578671 JM |
5891 | 2016-06-20 Joseph Myers <joseph@codesourcery.com> |
5892 | ||
5893 | PR c/71601 | |
5894 | * c-typeck.c (build_conditional_expr): Return error_mark_node if | |
5895 | c_common_type returns error_mark_node. | |
5896 | ||
3f8257db | 5897 | 2016-06-19 Martin Sebor <msebor@redhat.com> |
aa0db437 MS |
5898 | |
5899 | PR c/69507 | |
5900 | * c-parser.c (c_parser_alignof_expression): Avoid diagnosing | |
5901 | __alignof__ (expression). | |
5902 | ||
6a3f203c DM |
5903 | 2016-06-14 David Malcolm <dmalcolm@redhat.com> |
5904 | ||
5905 | * c-typeck.c: Include spellcheck-tree.h rather than spellcheck.h. | |
5906 | ||
264757fb DM |
5907 | 2016-06-14 David Malcolm <dmalcolm@redhat.com> |
5908 | ||
5909 | * c-typeck.c (build_component_ref): Simplify fixit code by | |
5910 | using gcc_rich_location::add_fixit_misspelled_id. | |
5911 | (set_init_label): Likewise. | |
5912 | ||
f7e4f2e3 DM |
5913 | 2016-06-13 David Malcolm <dmalcolm@redhat.com> |
5914 | ||
5915 | * c-parser.c (c_parser_initelt): Provide location of name for new | |
5916 | location_t param of set_init_label. | |
5917 | * c-tree.h (set_init_label): Add location_t param. | |
5918 | * c-typeck.c (set_init_index): Add "fieldname_loc" location_t | |
5919 | param and use it when issuing error messages about unrecognized | |
5920 | field names. Attempt to provide a fixit hint if appropriate, | |
5921 | otherwise update the error message to provide the type name. | |
5922 | ||
4b1ffdb1 TS |
5923 | 2016-06-10 Thomas Schwinge <thomas@codesourcery.com> |
5924 | ||
5925 | PR c/71381 | |
5926 | * c-parser.c (c_parser_omp_variable_list) <OMP_CLAUSE__CACHE_>: | |
5927 | Loosen checking. | |
5928 | ||
44a845ca MS |
5929 | 2016-06-08 Martin Sebor <msebor@redhat.com> |
5930 | Jakub Jelinek <jakub@redhat.com> | |
5931 | ||
5932 | PR c++/70507 | |
5933 | PR c/68120 | |
5934 | * c-typeck.c (convert_arguments): Don't promote last argument | |
5935 | of BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P. | |
5936 | ||
92a5f2ba MP |
5937 | 2016-06-08 Marek Polacek <polacek@redhat.com> |
5938 | ||
5939 | PR c/71418 | |
5940 | * c-decl.c (grokdeclarator): Check TYPE_P. | |
5941 | ||
08203f73 MP |
5942 | PR c/71426 |
5943 | * c-decl.c (get_parm_info): Don't crash on an assert on invalid | |
5944 | code. | |
5945 | ||
6ffd47b7 DM |
5946 | 2016-06-07 David Malcolm <dmalcolm@redhat.com> |
5947 | ||
5948 | * c-parser.c (c_parser_postfix_expression): In __builtin_offsetof | |
5949 | and structure element reference, capture the location of the | |
5950 | element name token and pass it to build_component_ref. | |
5951 | (c_parser_postfix_expression_after_primary): Likewise for | |
5952 | structure element dereference. | |
5953 | (c_parser_omp_variable_list): Likewise for | |
5954 | OMP_CLAUSE_{_CACHE, MAP, FROM, TO}, | |
5955 | * c-tree.h (build_component_ref): Add location_t param. | |
5956 | * c-typeck.c (build_component_ref): Add location_t param | |
5957 | COMPONENT_LOC. Use it, if available, when issuing hints about | |
5958 | mispelled member names to provide a fixit replacement hint. | |
5959 | ||
1f40cff3 MP |
5960 | 2016-06-06 Marek Polacek <polacek@redhat.com> |
5961 | ||
5962 | PR c/71362 | |
5963 | * c-parser.c (c_parser_direct_declarator): Set location. | |
5964 | ||
5545a907 MP |
5965 | 2016-06-06 Marek Polacek <polacek@redhat.com> |
5966 | ||
5967 | * c-typeck.c (comptypes_internal): Handle comparisons of | |
5968 | INTEGER_TYPE, FIXED_POINT_TYPE, and REAL_TYPE nodes. Don't check | |
5969 | TYPE_REF_CAN_ALIAS_ALL. | |
5970 | ||
b605f663 CLT |
5971 | 2016-06-03 Chung-Lin Tang <cltang@codesourcery.com> |
5972 | ||
5973 | * c-typeck.c (c_finish_omp_clauses): Mark OpenACC reduction | |
5974 | arguments as addressable when async clause exists. | |
5975 | ||
00631022 JJ |
5976 | 2016-05-30 Jakub Jelinek <jakub@redhat.com> |
5977 | ||
5978 | PR c++/71349 | |
5979 | * c-parser.c (c_parser_omp_for): Don't disallow nowait clause | |
5980 | when combined with target construct. | |
5981 | ||
7211a097 JJ |
5982 | 2016-05-26 Jakub Jelinek <jakub@redhat.com> |
5983 | ||
5984 | * c-parser.c (c_parser_omp_clause_schedule): Warn if | |
5985 | OMP_CLAUSE_SCHEDULE_CHUNK_EXPR is known not to be positive. | |
5986 | ||
95efe6b6 MP |
5987 | 2016-05-25 Marek Polacek <polacek@redhat.com> |
5988 | ||
5989 | PR c/71265 | |
5990 | * c-decl.c (c_make_fname_decl): Don't check seen_error. | |
5991 | ||
a23faf7a MP |
5992 | PR c/71266 |
5993 | * c-decl.c (store_parm_decls_oldstyle): Skip non-PARM_DECLs. | |
5994 | ||
e46c7770 CP |
5995 | 2016-05-24 Cesar Philippidis <cesar@codesourcery.com> |
5996 | ||
5997 | * c-parser.c (c_parser_oacc_declare): Add support for | |
5998 | GOMP_MAP_FIRSTPRIVATE_POINTER. | |
5999 | * c-typeck.c (handle_omp_array_sections_1): Replace bool is_omp | |
6000 | argument with enum c_omp_region_type ort. | |
6001 | (handle_omp_array_sections): Likewise. Update call to | |
6002 | handle_omp_array_sections_1. | |
6003 | (c_finish_omp_clauses): Add specific errors and warning messages for | |
6004 | OpenACC. Use firsrtprivate pointers for OpenACC subarrays. Update | |
6005 | call to handle_omp_array_sections. | |
6006 | ||
a04e69c0 TS |
6007 | 2016-05-24 Thomas Schwinge <thomas@codesourcery.com> |
6008 | ||
6009 | * c-parser.c (c_parser_oacc_routine): Tighten syntax checks. | |
6010 | ||
f17a223d RB |
6011 | 2016-05-24 Richard Biener <rguenther@suse.de> |
6012 | ||
6013 | PR middle-end/70434 | |
6014 | PR c/69504 | |
6015 | * c-typeck.c (build_array_ref): Do not complain about indexing | |
6016 | non-lvalue vectors. Adjust for function name change. | |
6017 | ||
79063edd MS |
6018 | 2016-05-20 Martin Sebor <msebor@redhat.com> |
6019 | ||
6020 | PR c/71115 | |
6021 | * c-typeck.c (error_init): Use | |
6022 | expansion_point_location_if_in_system_header. | |
6023 | (warning_init): Same. | |
6024 | ||
8a40fef3 DM |
6025 | 2016-05-19 David Malcolm <dmalcolm@redhat.com> |
6026 | ||
6027 | PR c/71171 | |
6028 | * c-parser.c (c_parser_generic_selection): Use c_expr::set_error | |
6029 | in error-handling. | |
6030 | (c_parser_postfix_expression): Likewise. | |
6031 | * c-tree.h (c_expr::set_error): New method. | |
6032 | * c-typeck.c (parser_build_binary_op): In error-handling, ensure | |
6033 | that result's range is initialized. | |
6034 | ||
e9892350 JG |
6035 | 2016-05-17 James Greenhalgh <james.greenhalgh@arm.com> |
6036 | ||
6037 | * c-typeck.c (parser_build_unary_op): Fix formatting. | |
6038 | ||
8fad45f5 MW |
6039 | 2016-05-16 Matthew Wahab <matthew.wahab@arm.com> |
6040 | ||
6041 | * c-decl.c (grokdeclarator): Remove errmsg and use of | |
6042 | targetm.invalid_return_type. | |
6043 | (grokparms): Remove errmsg and use of | |
6044 | targetm.invalid_parameter_type. | |
6045 | ||
aa4b467b JM |
6046 | 2016-05-13 Joseph Myers <joseph@codesourcery.com> |
6047 | ||
6048 | * c-decl.c (grokdeclarator): For C11, discard qualifiers on | |
6049 | function return type. | |
6050 | ||
4f2e1536 MP |
6051 | 2016-05-12 Marek Polacek <polacek@redhat.com> |
6052 | ||
6053 | PR c/70756 | |
6054 | * c-decl.c (build_compound_literal): Pass LOC down to | |
6055 | c_incomplete_type_error. | |
6056 | * c-tree.h (require_complete_type): Adjust declaration. | |
6057 | (c_incomplete_type_error): Likewise. | |
6058 | * c-typeck.c (require_complete_type): Add location parameter, pass it | |
6059 | down to c_incomplete_type_error. | |
6060 | (c_incomplete_type_error): Add location parameter, pass it down to | |
6061 | error_at. | |
6062 | (build_component_ref): Pass location down to c_incomplete_type_error. | |
6063 | (default_conversion): Pass location down to require_complete_type. | |
6064 | (build_array_ref): Likewise. | |
6065 | (build_function_call_vec): Likewise. | |
6066 | (convert_arguments): Likewise. | |
6067 | (build_unary_op): Likewise. | |
6068 | (build_c_cast): Likewise. | |
6069 | (build_modify_expr): Likewise. | |
6070 | (convert_for_assignment): Likewise. | |
6071 | (c_finish_omp_clauses): Likewise. | |
6072 | ||
d6e83a8d MM |
6073 | 2016-05-11 Mikhail Maltsev <maltsevm@gmail.com> |
6074 | ||
6075 | PR c/43651 | |
6076 | * c-decl.c (declspecs_add_qual): Warn when -Wduplicate-decl-specifier | |
6077 | is enabled. | |
6078 | * c-errors.c (pedwarn_c90): Return true if warned. | |
6079 | * c-tree.h (pedwarn_c90): Change return type to bool. | |
6080 | (enum c_declspec_word): Add new enumerator cdw_atomic. | |
6081 | ||
5c3a10fb MP |
6082 | 2016-05-11 Marek Polacek <polacek@redhat.com> |
6083 | ||
6084 | PR c++/71024 | |
6085 | * c-decl.c (diagnose_mismatched_decls): Factor out code to | |
6086 | diagnose_mismatched_attributes and call it. | |
6087 | ||
cf68d92c MP |
6088 | 2016-05-10 Marek Polacek <polacek@redhat.com> |
6089 | ||
6090 | PR c/70255 | |
6091 | * c-decl.c (diagnose_mismatched_decls): Warn for optimize attribute | |
6092 | on a declaration following the definition. | |
6093 | ||
351f85c5 JJ |
6094 | 2016-05-05 Jakub Jelinek <jakub@redhat.com> |
6095 | ||
6096 | * c-parser.c (c_parser_switch_statement): Add IF_P argument, | |
6097 | parse it through to c_parser_c99_block_statement. | |
6098 | (c_parser_statement_after_labels): Adjust c_parser_switch_statement | |
6099 | caller. | |
6100 | ||
deef7113 MP |
6101 | 2016-05-04 Marek Polacek <polacek@redhat.com> |
6102 | ||
6103 | * c-parser.c (c_parser_if_statement): Replace OPT_Wparentheses with | |
6104 | OPT_Wdangling_else. | |
6105 | ||
de55efd5 MP |
6106 | 2016-05-04 Marek Polacek <polacek@redhat.com> |
6107 | ||
6108 | PR c/48778 | |
6109 | * c-typeck.c (build_binary_op): Don't issue -Waddress warnings | |
6110 | for macro expansions. | |
6111 | ||
79ce98bc MP |
6112 | 2016-05-03 Marek Polacek <polacek@redhat.com> |
6113 | ||
6114 | PR c/70859 | |
6115 | * c-typeck.c (build_function_call_vec): Pass LOC and ARG_LOC down to | |
6116 | check_builtin_function_arguments. | |
6117 | ||
fb2647aa RB |
6118 | 2016-05-03 Richard Biener <rguenther@suse.de> |
6119 | ||
6120 | * Make-lang.in (cc1-checksum.c): For stage-final re-use | |
6121 | the checksum from the previous stage. | |
6122 | ||
77886428 CP |
6123 | 2016-05-02 Cesar Philippidis <cesar@codesourcery.com> |
6124 | ||
6125 | * c-parser.c (c_parser_oacc_all_clauses): Update call to | |
6126 | c_finish_omp_clauses. | |
6127 | (c_parser_omp_all_clauses): Likewise. | |
6128 | (c_parser_oacc_cache): Likewise. | |
6129 | (c_parser_oacc_loop): Likewise. | |
6130 | (omp_split_clauses): Likewise. | |
6131 | (c_parser_omp_declare_target): Likewise. | |
6132 | (c_parser_cilk_all_clauses): Likewise. | |
6133 | (c_parser_cilk_for): Likewise. | |
6134 | * c-typeck.c (c_finish_omp_clauses): Replace bool arguments | |
6135 | is_omp, declare_simd, and is_cilk with enum c_omp_region_type ort. | |
6136 | ||
7176a4a0 MP |
6137 | 2016-05-02 Marek Polacek <polacek@redhat.com> |
6138 | ||
6139 | PR c/70851 | |
6140 | * c-decl.c (grokdeclarator): Diagnose when array's size has an | |
6141 | incomplete type. | |
6142 | ||
e7ff0319 CP |
6143 | 2016-04-29 Cesar Philippidis <cesar@codesourcery.com> |
6144 | ||
6145 | PR middle-end/70626 | |
6146 | * c-parser.c (c_parser_oacc_loop): Don't augment mask with | |
6147 | OACC_LOOP_CLAUSE_MASK. | |
6148 | (c_parser_oacc_kernels_parallel): Update call to | |
6149 | c_oacc_split_loop_clauses. | |
6150 | ||
9f405ce1 AM |
6151 | 2016-04-28 Andrew MacLeod <amacleod@redhat.com> |
6152 | ||
6153 | * c-array-notation.c (fix_builtin_array_notation_fn): Fix final | |
6154 | argument to build_modify_expr in two cases. | |
6155 | ||
c1e1f433 BS |
6156 | 2016-04-27 Bernd Schmidt <bschmidt@redhat.com> |
6157 | ||
6158 | * c-parser.c (c_parser_postfix_expression_after_primary): Call | |
6159 | warn_for_memset instead of warning directly here. | |
6160 | ||
2448a956 MP |
6161 | 2016-04-26 Marek Polacek <polacek@redhat.com> |
6162 | ||
6163 | PR c/67784 | |
6164 | * c-parser.c (c_parser_maybe_reclassify_token): New function factored | |
6165 | out of ... | |
6166 | (c_parser_for_statement): ... here. | |
6167 | (c_parser_if_statement): Use it. | |
6168 | (c_parser_switch_statement): Use it. | |
6169 | (c_parser_while_statement): Use it. | |
6170 | ||
b02a5e26 MP |
6171 | PR c/70791 |
6172 | * c-decl.c (pushdecl): Pass LOCUS down to warning. | |
6173 | ||
477d4906 IV |
6174 | 2016-04-20 Ilya Verbin <ilya.verbin@intel.com> |
6175 | ||
6176 | PR c++/69363 | |
6177 | * c-parser.c (c_parser_cilk_all_clauses): Use c_finish_omp_clauses | |
6178 | instead of c_finish_cilk_clauses. | |
6179 | * c-tree.h (c_finish_omp_clauses): Add new default argument. | |
6180 | * c-typeck.c (c_finish_omp_clauses): Add new argument. Allow | |
6181 | floating-point variables in the linear clause for Cilk Plus. | |
6182 | ||
fe37c7af MM |
6183 | 2016-04-18 Michael Matz <matz@suse.de> |
6184 | ||
6185 | * c-decl.c (merge_decls): Use SET_DECL_ALIGN and SET_TYPE_ALIGN. | |
6186 | (grokdeclarator, parser_xref_tag, finish_enum): Use SET_TYPE_ALIGN. | |
6187 | ||
949505a9 MP |
6188 | 2016-04-15 Marek Polacek <polacek@redhat.com> |
6189 | ||
6190 | PR c/70671 | |
6191 | * c-typeck.c (build_unary_op): Pass location down to error and | |
6192 | warning call. | |
6193 | ||
dda1bf61 JJ |
6194 | 2016-04-15 Jakub Jelinek <jakub@redhat.com> |
6195 | ||
6196 | PR c/70436 | |
6197 | * c-parser.c (c_parser_pragma): Add IF_P argument, pass it down | |
6198 | where needed. | |
6199 | (c_parser_external_declaration, c_parser_struct_or_union_specifier, | |
6200 | c_parser_parameter_declaration, c_parser_compound_statement_nostart, | |
6201 | c_parser_objc_class_instance_variables, c_parser_objc_methodprotolist): | |
6202 | Adjust c_parser_pragma callers. | |
6203 | (c_parser_statement_after_labels): Likewise. Adjust c_parser_cilk_for | |
6204 | caller. | |
6205 | (c_parser_omp_structured_block): Add IF_P argument, pass it down to | |
6206 | c_parser_statement. | |
6207 | (c_parser_oacc_data, c_parser_oacc_host_data, c_parser_oacc_loop, | |
6208 | c_parser_oacc_kernels_parallel, c_parser_omp_critical, | |
6209 | c_parser_omp_simd, c_parser_omp_for, c_parser_omp_master, | |
6210 | c_parser_omp_ordered, c_parser_omp_parallel, c_parser_omp_single, | |
6211 | c_parser_omp_task, c_parser_omp_taskgroup, c_parser_omp_distribute, | |
6212 | c_parser_omp_teams, c_parser_omp_target_data, c_parser_omp_target, | |
6213 | c_parser_omp_taskloop, c_parser_omp_construct, c_parser_cilk_grainsize, | |
6214 | c_parser_cilk_simd, c_parser_cilk_for): Add IF_P argument, pass it | |
6215 | down where needed. | |
6216 | (c_parser_omp_for_loop): Likewise. Clear IF_P if nbraces. | |
6217 | (c_parser_omp_sections_scope): Adjust c_parser_omp_structured_block | |
6218 | calls. | |
6219 | ||
99cd9857 MP |
6220 | 2016-04-13 Marek Polacek <polacek@redhat.com> |
6221 | ||
6222 | PR c/70436 | |
6223 | * c-parser.c (c_parser_statement_after_labels): Add IF_P argument and | |
6224 | adjust callers. | |
6225 | (c_parser_statement): Likewise. | |
6226 | (c_parser_c99_block_statement): Likewise. | |
6227 | (c_parser_while_statement): Likewise. | |
6228 | (c_parser_for_statement): Likewise. | |
6229 | (c_parser_if_body): Don't set IF_P here. | |
6230 | (c_parser_if_statement): Add IF_P argument. Set IF_P here. Warn | |
6231 | about dangling else here. | |
6232 | * c-tree.h (c_finish_if_stmt): Adjust declaration. | |
6233 | * c-typeck.c (c_finish_if_stmt): Remove NESTED_IF parameter. Don't | |
6234 | warn about dangling else here. | |
6235 | ||
f13355da MP |
6236 | 2016-04-04 Marek Polacek <polacek@redhat.com> |
6237 | ||
6238 | PR c/70307 | |
6239 | * c-fold.c (c_fully_fold_internal): Handle VEC_COND_EXPR. | |
6240 | ||
5fde6a45 MP |
6241 | 2016-03-31 Marek Polacek <polacek@redhat.com> |
6242 | ||
6243 | PR c/70297 | |
6244 | * c-decl.c (merge_decls): Also set TYPE_ALIGN and TYPE_USER_ALIGN. | |
6245 | ||
4bbf545b DM |
6246 | 2016-03-18 David Malcolm <dmalcolm@redhat.com> |
6247 | ||
6248 | PR c/70281 | |
6249 | * c-parser.c (c_parser_postfix_expression): Set the source range | |
6250 | for uses of "__builtin_types_compatible_p". | |
6251 | ||
fcc2b74f JJ |
6252 | 2016-03-17 Jakub Jelinek <jakub@redhat.com> |
6253 | ||
6254 | PR c/70280 | |
6255 | * c-typeck.c (composite_type): Don't count void_list_node | |
6256 | into len, if the list is terminated by void_list_node, start | |
6257 | with void_list_node instead of NULL for newargs. Stop | |
6258 | at void_list_node. | |
6259 | ||
ab4c578f MP |
6260 | 2016-03-16 Marek Polacek <polacek@redhat.com> |
6261 | ||
6262 | PR c/70093 | |
6263 | * c-typeck.c (build_function_call_vec): Create a TARGET_EXPR for | |
6264 | nested functions returning VM types. | |
6265 | ||
96b3c82d CP |
6266 | 2016-03-09 Cesar Philippidis <cesar@codesourcery.com> |
6267 | ||
6268 | * c-parser.c (c_parser_oacc_loop): Update cclauses and clauses | |
6269 | when calling c_finish_omp_clauses. | |
6270 | ||
29b9828f BS |
6271 | 2016-03-04 Bernd Schmidt <bschmidt@redhat.com> |
6272 | ||
6273 | PR c/69824 | |
6274 | * c-decl.c (get_parm_info): Don't queue implicit function declarations | |
6275 | for later. | |
6276 | ||
7ff6ca38 MP |
6277 | 2016-03-04 Marek Polacek <polacek@redhat.com> |
6278 | ||
6279 | PR c/69798 | |
6280 | * c-parser.c (c_parser_postfix_expression): Call | |
6281 | c_parser_cast_expression rather than c_parser_postfix_expression. | |
6282 | ||
686e2237 JJ |
6283 | 2016-03-01 Jakub Jelinek <jakub@redhat.com> |
6284 | ||
6285 | PR c/69796 | |
6286 | PR c/69974 | |
6287 | * c-parser.c (c_parser_translation_unit): Don't change TREE_TYPE | |
6288 | of incomplete decls to error_mark_node. | |
6289 | ||
0b05329b MP |
6290 | 2016-02-24 Marek Polacek <polacek@redhat.com> |
6291 | ||
6292 | PR c/69819 | |
6293 | * c-decl.c (finish_decl): Don't update the copy of the type of a | |
6294 | different decl type. | |
6295 | ||
067fbd8b JJ |
6296 | 2016-02-23 Jakub Jelinek <jakub@redhat.com> |
6297 | ||
6298 | PR objc/69844 | |
6299 | * c-parser.c (c_parser_for_statement): Properly handle ObjC classes | |
6300 | in id_kind reclassification. | |
6301 | ||
bf14eba2 JJ |
6302 | 2016-02-16 Jakub Jelinek <jakub@redhat.com> |
6303 | ||
6304 | PR c/69835 | |
6305 | * c-typeck.c (build_binary_op): Revert 2015-09-09 change. | |
6306 | ||
ba539195 JN |
6307 | 2016-02-16 James Norris <jnorris@codesourcery.com> |
6308 | ||
6309 | PR c/64748 | |
6310 | * c-parser.c (c_parser_oacc_data_clause_deviceptr): Allow parms. | |
6311 | ||
16595a1f BS |
6312 | 2016-02-12 Bernd Schmidt <bschmidt@redhat.com> |
6313 | ||
f48dfe98 BS |
6314 | * c-decl.c (build_null_declspecs): Zero the entire struct. |
6315 | ||
16595a1f BS |
6316 | PR c/69522 |
6317 | * c-parser.c (c_parser_braced_init): New arg outer_obstack. All | |
6318 | callers changed. If nested_p is true, use it to call | |
6319 | finish_implicit_inits. | |
6320 | * c-tree.h (finish_implicit_inits): Declare. | |
6321 | * c-typeck.c (finish_implicit_inits): New function. Move code | |
6322 | from ... | |
6323 | (push_init_level): ... here. | |
6324 | (set_designator, process_init_element): Call finish_implicit_inits. | |
6325 | ||
66756373 JJ |
6326 | 2016-02-11 Jakub Jelinek <jakub@redhat.com> |
6327 | ||
6328 | PR c/69768 | |
6329 | * c-typeck.c (parser_build_binary_op): Strip nops from integer_zerop | |
6330 | arguments for -Waddress warning. | |
6331 | ||
1066e9b5 JJ |
6332 | 2016-02-04 Jakub Jelinek <jakub@redhat.com> |
6333 | ||
6334 | PR c/69669 | |
6335 | * c-decl.c (finish_enum): When honoring mode attribute, | |
6336 | make sure to use proper TYPE_MIN_VALUE and TYPE_MAX_VALUE. | |
6337 | ||
3a5d2ba4 JJ |
6338 | 2016-01-29 Jakub Jelinek <jakub@redhat.com> |
6339 | ||
6340 | PR debug/69518 | |
6341 | * c-decl.c (finish_struct): Clear C_TYPE_INCOMPLETE_VARS in | |
6342 | all type variants, not just TYPE_MAIN_VARIANT. | |
6343 | ||
cbdd8ae0 JJ |
6344 | 2016-01-27 Jakub Jelinek <jakub@redhat.com> |
6345 | ||
6346 | PR debug/66869 | |
6347 | * c-decl.c (c_write_global_declarations_1): Warn with | |
6348 | warn_unused_function if static prototype without definition | |
6349 | is not C_DECL_USED. | |
6350 | ||
fa74a4bc MP |
6351 | 2016-01-27 Marek Polacek <polacek@redhat.com> |
6352 | ||
6353 | PR c/68062 | |
6354 | * c-typeck.c (build_binary_op) [EQ_EXPR, GE_EXPR]: Promote operand | |
6355 | to unsigned, if needed. Add -Wsign-compare warning. | |
6356 | ||
13f92e8d JJ |
6357 | 2016-01-26 Jakub Jelinek <jakub@redhat.com> |
6358 | ||
6359 | PR tree-optimization/69483 | |
6360 | * c-parser.c (c_parser_translation_unit): Use FOR_EACH_VEC_ELT. | |
6361 | ||
cd8e73dc | 6362 | 2016-01-20 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
d25c7690 PK |
6363 | |
6364 | PR c/24293 | |
6365 | * c-tree.h (incomplete_record_decls): Declare. | |
6366 | * c-parser.c (incomplete_record_decls): Define. | |
6367 | (c_parser_translation_unit): Iterate through incomplete_record_decls and | |
6368 | report error if any decl has zero size. | |
6369 | * c-decl.c (finish_decl): Append static decl with incomplete struct/union | |
6370 | or enum type to incomplete_record_decls. | |
6371 | ||
e6d6ec9e TV |
6372 | 2016-01-14 Tom de Vries <tom@codesourcery.com> |
6373 | ||
6374 | PR tree-optimization/68773 | |
6375 | * c-parser.c (c_parser_oacc_declare, c_parser_omp_declare_target): Don't | |
6376 | set force_output. | |
6377 | ||
00083992 MP |
6378 | 2016-01-14 Marek Polacek <polacek@redhat.com> |
6379 | ||
6380 | PR c/69262 | |
6381 | * c-decl.c (grokdeclarator): Provide more information for invalid | |
6382 | array declarations. | |
6383 | ||
7443cf13 DM |
6384 | 2016-01-06 David Malcolm <dmalcolm@redhat.com> |
6385 | ||
6386 | * c-parser.c (c_parser_unary_expression): For dereferences, build | |
6387 | a combined location before calling build_indirect_ref, so that | |
6388 | error reports cover the full range, manually updating the c_expr | |
6389 | src_range. | |
6390 | ||
6b131d5b MP |
6391 | 2016-01-06 Marek Polacek <polacek@redhat.com> |
6392 | ||
6393 | PR sanitizer/69099 | |
6394 | * c-convert.c (convert) [INTEGER_TYPE]: Drop ARG. Don't pass ARG to | |
6395 | ubsan_instrument_float_cast. Fold EXPR. Use NULL_TREE instead of | |
6396 | NULL. | |
6397 | ||
818ab71a JJ |
6398 | 2016-01-04 Jakub Jelinek <jakub@redhat.com> |
6399 | ||
6400 | Update copyright years. | |
6401 | ||
2fe0a208 MP |
6402 | 2016-01-04 Marek Polacek <polacek@redhat.com> |
6403 | ||
6404 | PR c/68908 | |
6405 | * c-typeck.c (build_atomic_assign): Improve commentary. Add | |
6406 | optimization to use __atomic_fetch_* built-in if possible. | |
6407 | ||
c7b48c8a TS |
6408 | 2015-12-23 Thomas Schwinge <thomas@codesourcery.com> |
6409 | ||
6410 | * c-parser.c (c_parser_oacc_clause_use_device): Merge function | |
6411 | into... | |
6412 | (c_parser_omp_clause_use_device_ptr): ... this function. Adjust | |
6413 | all users. | |
6414 | ||
fda5652f MP |
6415 | 2015-12-22 Marek Polacek <polacek@redhat.com> |
6416 | ||
6417 | PR c/69002 | |
6418 | * c-typeck.c (build_component_ref): Warn when acessing elements of | |
6419 | atomic structures or unions. | |
6420 | ||
745e411d DM |
6421 | 2015-12-21 David Malcolm <dmalcolm@redhat.com> |
6422 | ||
6423 | * c-typeck.c: Include "gcc-rich-location.h". | |
6424 | (build_binary_op): In the two places that call binary_op_error, | |
6425 | create a gcc_rich_location and populate it with the location of | |
6426 | the binary op and its two operands. | |
6427 | ||
94c40e19 DM |
6428 | 2015-12-16 David Malcolm <dmalcolm@redhat.com> |
6429 | ||
6430 | * c-parser.c (c_parser_statement_after_labels): When calling | |
6431 | c_finish_return, Use the return expression's location if it has | |
6432 | one, falling back to the location of the first token within it. | |
6433 | * c-typeck.c (c_finish_return): When issuing warnings about | |
6434 | the incorrect presence/absence of a return value, issue a note | |
6435 | showing the declaration of the function. | |
6436 | ||
de67c4c3 DM |
6437 | 2015-12-16 David Malcolm <dmalcolm@redhat.com> |
6438 | ||
6439 | * c-parser.c (struct c_parser): Expand array "tokens_buf" from 2 | |
6440 | to 4. | |
6441 | (c_parser_peek_nth_token): New function. | |
6442 | (c_parser_peek_conflict_marker): New function. | |
6443 | (c_parser_error): Detect conflict markers and report them as such. | |
6444 | ||
a10704e1 DM |
6445 | 2015-12-16 David Malcolm <dmalcolm@redhat.com> |
6446 | ||
6447 | * c-parser.c (c_parser_postfix_expression): Use EXPR_LOC_OR_LOC | |
6448 | to preserve range information for the primary expression | |
6449 | in the call to c_parser_postfix_expression_after_primary. | |
6450 | ||
8062bca6 DM |
6451 | 2015-12-16 David Malcolm <dmalcolm@redhat.com> |
6452 | ||
6453 | * c-parser.c (c_parser_static_assert_declaration_no_semi): Use the | |
6454 | expression location, falling back on the first token location, | |
6455 | rather than always using the latter. | |
6456 | ||
d06f8b75 MP |
6457 | 2015-12-16 Marek Polacek <polacek@redhat.com> |
6458 | ||
6459 | PR c/64637 | |
6460 | * c-typeck.c (c_process_expr_stmt): Use location of the expression if | |
6461 | available. | |
6462 | ||
2994fb91 MP |
6463 | 2015-12-15 Marek Polacek <polacek@redhat.com> |
6464 | ||
6465 | PR c/68907 | |
6466 | * c-typeck.c (build_atomic_assign): Set TREE_NO_WARNING on an | |
6467 | artificial decl. | |
6468 | ||
a1b93f8d DM |
6469 | 2015-12-08 David Malcolm <dmalcolm@redhat.com> |
6470 | ||
6471 | * c-parser.c (c_parser_alignof_expression): Capture location of | |
6472 | closing parenthesis (if any), or of end of unary expression, and | |
6473 | use it to build a src_range for the expression. | |
6474 | ||
46c6e1e2 DM |
6475 | 2015-12-08 David Malcolm <dmalcolm@redhat.com> |
6476 | ||
6477 | PR c/68757 | |
6478 | * c-parser.c (c_parser_get_builtin_args): Add | |
6479 | "out_close_paren_loc" param, and write back to it. | |
6480 | (c_parser_postfix_expression): Capture the closing | |
6481 | parenthesis location for RID_CHOOSE_EXPR, | |
6482 | RID_BUILTIN_CALL_WITH_STATIC_CHAIN, RID_BUILTIN_COMPLEX, | |
6483 | RID_BUILTIN_SHUFFLE and use it to set the source range | |
6484 | for such expressions; within RID_BUILTIN_COMPLEX set | |
6485 | the underlying location. | |
6486 | ||
66189108 MP |
6487 | 2015-12-07 Marek Polacek <polacek@redhat.com> |
6488 | ||
6489 | PR c/68668 | |
6490 | * c-decl.c (grokdeclarator): If ORIG_QUAL_INDIRECT is indirect, use | |
6491 | TREE_TYPE of ORIG_QUAL_TYPE, otherwise decrement ORIG_QUAL_INDIRECT. | |
6492 | ||
f187980b EB |
6493 | 2015-12-04 Eric Botcazou <ebotcazou@adacore.com> |
6494 | ||
6495 | * c-tree.h (c_build_va_arg): Adjust prototype. | |
6496 | * c-parser.c (c_parser_postfix_expression): Adjust call to above. | |
6497 | * c-typeck.c (c_build_va_arg): Rename LOC parameter to LOC2, add LOC1 | |
6498 | parameter, adjust throughout and issue an error if EXPR is a component | |
6499 | with reverse storage order. | |
6500 | ||
4250754e JM |
6501 | 2015-12-02 Jason Merrill <jason@redhat.com> |
6502 | ||
6503 | * c-fold.c (c_disable_warnings, c_enable_warnings, c_fully_fold) | |
6504 | (c_fully_fold_internal, decl_constant_value_for_optimization): | |
6505 | Move from c-common.c. | |
6506 | * c-tree.h: Declare decl_constant_value_for_optimization. | |
6507 | * Make-lang.in (C_AND_OBJC_OBJS): Add c-fold.o. | |
6508 | ||
e9e32ee6 JM |
6509 | 2015-12-02 Joseph Myers <joseph@codesourcery.com> |
6510 | ||
6511 | PR c/68162 | |
6512 | * c-decl.c (grokdeclarator): Set first_non_attr_kind before | |
6513 | following link from declarator to next declarator. Track original | |
6514 | qualified type and pass it to c_build_qualified_type. | |
6515 | * c-typeck.c (c_build_qualified_type): Add arguments | |
6516 | orig_qual_type and orig_qual_indirect. | |
6517 | ||
ff7a55bf TS |
6518 | 2015-12-02 Thomas Schwinge <thomas@codesourcery.com> |
6519 | ||
6520 | * c-parser.c (c_parser_omp_clause_name) | |
6521 | (c_parser_oacc_all_clauses): Alphabetical sorting. | |
6522 | ||
657e4e47 JJ |
6523 | 2015-12-02 Jakub Jelinek <jakub@redhat.com> |
6524 | ||
6525 | PR c/68533 | |
6526 | * c-decl.c (get_parm_info): Use b->locus instead of input_location | |
6527 | for diagnostics. | |
6528 | ||
37d5ad46 JB |
6529 | 2015-12-01 Julian Brown <julian@codesourcery.com> |
6530 | Cesar Philippidis <cesar@codesourcery.com> | |
6531 | James Norris <James_Norris@mentor.com> | |
6532 | ||
6533 | * c-parser.c (c_parser_omp_clause_name): Add use_device support. | |
6534 | (c_parser_oacc_clause_use_device): New function. | |
6535 | (c_parser_oacc_all_clauses): Add use_device support. | |
6536 | (OACC_HOST_DATA_CLAUSE_MASK): New macro. | |
6537 | (c_parser_oacc_host_data): New function. | |
6538 | (c_parser_omp_construct): Add host_data support. | |
6539 | * c-tree.h (c_finish_oacc_host_data): Add prototype. | |
6540 | * c-typeck.c (c_finish_oacc_host_data): New function. | |
6541 | (c_finish_omp_clauses): Add use_device support. | |
6542 | ||
a4850ce9 JH |
6543 | 2015-11-29 Jan Hubicka <hubicka@ucw.cz> |
6544 | ||
6545 | PR c/67106 | |
6546 | * c-decl.c: Set TYPE_PACKED in variants. | |
6547 | ||
b58d3df2 ML |
6548 | 2015-11-27 Martin Liska <mliska@suse.cz> |
6549 | ||
6550 | PR c++/68312 | |
6551 | * c-array-notation.c (fix_builtin_array_notation_fn): | |
6552 | Use release_vec_vec instead of vec::release. | |
6553 | (build_array_notation_expr): Likewise. | |
6554 | (fix_conditional_array_notations_1): Likewise. | |
6555 | (fix_array_notation_expr): Likewise. | |
6556 | (fix_array_notation_call_expr): Likewise. | |
6557 | ||
aec17bfe JJ |
6558 | 2015-11-27 Jakub Jelinek <jakub@redhat.com> |
6559 | ||
6560 | PR c/63326 | |
6561 | * c-parser.c (c_parser_compound_statement_nostart): If | |
6562 | last_label is true, use pragma_stmt instead of pragma_compound | |
6563 | as second c_parser_pragma argument. | |
6564 | (c_parser_omp_ordered, c_parser_omp_target_update, | |
6565 | c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): Pass | |
6566 | false as second argument to c_parser_skip_to_pragma_eol after | |
6567 | diagnosing standalone directives used in pragma_stmt context. | |
6568 | ||
688c4de0 IV |
6569 | 2015-11-24 Ilya Verbin <ilya.verbin@intel.com> |
6570 | ||
6571 | * c-parser.c (c_parser_oacc_declare): Replace "ifdef ENABLE_OFFLOADING" | |
6572 | with "if (ENABLE_OFFLOADING)". | |
6573 | ||
cbd03aee DM |
6574 | 2015-11-23 David Malcolm <dmalcolm@redhat.com> |
6575 | ||
6576 | PR objc/68438 | |
6577 | * c-parser.c (c_parser_postfix_expression): Set up source ranges | |
6578 | for various Objective-C constructs: Class.name syntax, | |
6579 | @selector(), @protocol(), @encode(), and [] message syntax. | |
6580 | ||
a87a86e1 DM |
6581 | 2015-11-20 David Malcolm <dmalcolm@redhat.com> |
6582 | ||
6583 | PR 62314 | |
6584 | * c-typeck.c (should_suggest_deref_p): New function. | |
6585 | (build_component_ref): Special-case POINTER_TYPE when | |
6586 | generating a "not a structure of union" error message, and | |
6587 | suggest a "->" rather than a ".", providing a fix-it hint. | |
6588 | ||
8ece8dfb DM |
6589 | 2015-11-19 David Malcolm <dmalcolm@redhat.com> |
6590 | ||
6591 | * c-typeck.c (lookup_field_fuzzy): Move determination of closest | |
6592 | candidate into a new function, find_closest_identifier. | |
6593 | ||
433068cc MP |
6594 | 2015-11-19 Marek Polacek <polacek@redhat.com> |
6595 | ||
6596 | PR c/68412 | |
6597 | * c-typeck.c (parser_build_binary_op): Properly handle | |
6598 | C_MAYBE_CONST_EXPR before calling warn_tautological_cmp. | |
6599 | ||
bef08b71 DM |
6600 | 2015-11-17 David Malcolm <dmalcolm@redhat.com> |
6601 | ||
6602 | * c-parser.c (set_c_expr_source_range): Bulletproof both | |
6603 | overloaded implementations against NULL expr->value. | |
6604 | (c_parser_braced_init): Set src_range for "ret" to a sane pair of | |
6605 | values. | |
6606 | (c_parser_unary_expression): Likewise when handling addresses of | |
6607 | labels. | |
6608 | (c_parser_postfix_expression): Likewise for statement expressions, | |
6609 | for __FUNCTION__, __PRETTY_FUNCTION_ and __func__ keywords, for | |
6610 | __builtin_va_arg, and for __builtin_offset_of. | |
6611 | (c_parser_postfix_expression_after_paren_type): Initialize expr's | |
6612 | src_range using the range of the braced initializer. | |
6613 | (c_parser_transaction_expression): Set src_range for "ret" to a | |
6614 | sane pair of values. | |
6615 | ||
fff77217 KY |
6616 | 2015-11-16 Kirill Yukhin <kirill.yukhin@intel.com> |
6617 | ||
6618 | * c-parser.c (c_finish_omp_declare_simd): Look for | |
6619 | "simd" attribute as well. Update error message. | |
6620 | ||
1d899da2 TS |
6621 | 2015-11-14 Trevor Saunders <tbsaunde+gcc@tbsaunde.org> |
6622 | ||
6623 | * c-parser.c (c_parser_omp_declare_target): Adjust. | |
6624 | ||
e4606348 JJ |
6625 | 2015-11-14 Jakub Jelinek <jakub@redhat.com> |
6626 | ||
6627 | * c-typeck.c (c_finish_omp_clauses): Don't mark | |
6628 | GOMP_MAP_FIRSTPRIVATE_POINTER decls addressable. | |
6629 | ||
3e636daf MP |
6630 | 2015-11-14 Marek Polacek <polacek@redhat.com> |
6631 | ||
6632 | * c-decl.c: Use RECORD_OR_UNION_TYPE_P throughout. | |
6633 | * c-typeck.c: Likewise. | |
6634 | ||
ebedc9a3 DM |
6635 | 2015-11-13 David Malcolm <dmalcolm@redhat.com> |
6636 | ||
6637 | * c-decl.c (warn_defaults_to): Pass line_table to | |
6638 | rich_location ctor. | |
6639 | * c-errors.c (pedwarn_c99): Likewise. | |
6640 | (pedwarn_c90): Likewise. | |
6641 | * c-parser.c (set_c_expr_source_range): New functions. | |
6642 | (c_token::get_range): New method. | |
6643 | (c_token::get_finish): New method. | |
6644 | (c_parser_expr_no_commas): Call set_c_expr_source_range on the ret | |
6645 | based on the range from the start of the LHS to the end of the | |
6646 | RHS. | |
6647 | (c_parser_conditional_expression): Likewise, based on the range | |
6648 | from the start of the cond.value to the end of exp2.value. | |
6649 | (c_parser_binary_expression): Call set_c_expr_source_range on | |
6650 | the stack values for TRUTH_ANDIF_EXPR and TRUTH_ORIF_EXPR. | |
6651 | (c_parser_cast_expression): Call set_c_expr_source_range on ret | |
6652 | based on the cast_loc through to the end of the expr. | |
6653 | (c_parser_unary_expression): Likewise, based on the | |
6654 | op_loc through to the end of op. | |
6655 | (c_parser_sizeof_expression) Likewise, based on the start of the | |
6656 | sizeof token through to either the closing paren or the end of | |
6657 | expr. | |
6658 | (c_parser_postfix_expression): Likewise, using the token range, | |
6659 | or from the open paren through to the close paren for | |
6660 | parenthesized expressions. | |
6661 | (c_parser_postfix_expression_after_primary): Likewise, for | |
6662 | various kinds of expression. | |
6663 | * c-tree.h (struct c_expr): Add field "src_range". | |
6664 | (c_expr::get_start): New method. | |
6665 | (c_expr::get_finish): New method. | |
6666 | (set_c_expr_source_range): New decls. | |
6667 | * c-typeck.c (parser_build_unary_op): Call set_c_expr_source_range | |
6668 | on ret for prefix unary ops. | |
6669 | (parser_build_binary_op): Likewise, running from the start of | |
6670 | arg1.value through to the end of arg2.value. | |
6671 | ||
ec8b536f MP |
6672 | 2015-11-13 Marek Polacek <polacek@redhat.com> |
6673 | ||
6674 | PR c/68320 | |
6675 | * c-parser.c (c_parser_for_statement): Treat unknown tokens as IDs. | |
6676 | ||
277fe616 DM |
6677 | 2015-11-13 David Malcolm <dmalcolm@redhat.com> |
6678 | ||
6679 | * c-typeck.c: Include spellcheck.h. | |
6680 | (lookup_field_fuzzy_find_candidates): New function. | |
6681 | (lookup_field_fuzzy): New function. | |
6682 | (build_component_ref): If the field was not found, try using | |
6683 | lookup_field_fuzzy and potentially offer a suggestion. | |
6684 | ||
6e232ba4 JN |
6685 | 2015-11-12 James Norris <jnorris@codesourcery.com> |
6686 | Joseph Myers <joseph@codesourcery.com> | |
6687 | ||
6688 | * c-parser.c (c_parser_pragma): Handle PRAGMA_OACC_DECLARE. | |
6689 | (c_parser_omp_clause_name): Handle 'device_resident' clause. | |
6690 | (c_parser_oacc_data_clause): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT | |
6691 | and PRAGMA_OMP_CLAUSE_LINK. | |
6692 | (c_parser_oacc_all_clauses): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT | |
6693 | and PRAGMA_OACC_CLAUSE_LINK. | |
6694 | (OACC_DECLARE_CLAUSE_MASK): New definition. | |
6695 | (c_parser_oacc_declare): New function. | |
6696 | ||
9be4f715 MP |
6697 | 2015-11-12 Marek Polacek <polacek@redhat.com> |
6698 | ||
6699 | PR c/67784 | |
6700 | * c-parser.c (c_parser_for_statement): Reclassify the token in | |
6701 | a correct scope. | |
6702 | ||
e78bede6 MP |
6703 | 2015-11-11 Marek Polacek <polacek@redhat.com> |
6704 | ||
6705 | PR c/68107 | |
6706 | PR c++/68266 | |
6707 | * c-decl.c (grokdeclarator): Call valid_array_size_p. Remove code | |
6708 | checking the size of an array. | |
6709 | ||
69f293c9 AM |
6710 | 2015-11-11 Andrew MacLeod <amacleod@redhat.com> |
6711 | ||
6712 | * c-array-notation.c: Remove unused header files. | |
6713 | * c-aux-info.c: Likewise. | |
6714 | * c-convert.c: Likewise. | |
6715 | * c-decl.c: Likewise. | |
6716 | * c-errors.c: Likewise. | |
6717 | * c-lang.c: Likewise. | |
6718 | * c-objc-common.c: Likewise. | |
6719 | * c-parser.c: Likewise. | |
6720 | * c-typeck.c: Likewise. | |
6721 | * gccspec.c: Likewise. | |
6722 | ||
3a40d81d NS |
6723 | 2015-11-09 Thomas Schwinge <thomas@codesourcery.com> |
6724 | Cesar Philippidis <cesar@codesourcery.com> | |
6725 | James Norris <jnorris@codesourcery.com> | |
6726 | Julian Brown <julian@codesourcery.com> | |
6727 | Nathan Sidwell <nathan@codesourcery.com> | |
6728 | ||
3a40d81d NS |
6729 | * c-parser.c (c_parser_declaration_or_fndef): Add OpenACC |
6730 | routine arg. | |
6731 | (c_parser_declaration_or_fndef): Call c_finish_oacc_routine. | |
6732 | (c_parser_pragma): Parse 'acc routine'. | |
6733 | (OACC_ROUTINE_CLAUSE_MARK): Define. | |
6734 | (c_parser_oacc_routine, (c_finish_oacc_routine): New. | |
6735 | ||
fc402eec AA |
6736 | 2015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com> |
6737 | ||
6738 | PR debug/67192 | |
6739 | * c-typeck.c (c_finish_loop): For unconditional loops, set the | |
6740 | location of the backward-goto to the start of the loop body. | |
6741 | ||
f6b0b3db AA |
6742 | 2015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com> |
6743 | ||
6744 | PR debug/67192 | |
6745 | * c-parser.c (c_parser_while_statement): Finish the loop before | |
6746 | parsing ahead for misleading indentation. | |
6747 | (c_parser_for_statement): Likewise. | |
6748 | ||
ee45a32d EB |
6749 | 2015-11-08 Eric Botcazou <ebotcazou@adacore.com> |
6750 | ||
6751 | * c-decl.c (finish_struct): If the structure has reverse storage | |
6752 | order, rewrite the type of array fields with scalar component. Call | |
6753 | maybe_apply_pragma_scalar_storage_order on entry. | |
6754 | * c-typeck.c (build_unary_op) <ADDR_EXPR>: Remove left-overs. Issue | |
6755 | errors on bit-fields and reverse SSO here and not... | |
6756 | (c_mark_addressable): ...here. | |
6757 | (output_init_element): Adjust call to initializer_constant_valid_p. | |
6758 | (c_build_qualified_type): Propagate TYPE_REVERSE_STORAGE_ORDER. | |
6759 | ||
8a645150 DM |
6760 | 2015-11-06 David Malcolm <dmalcolm@redhat.com> |
6761 | ||
6762 | * c-decl.c (warn_defaults_to): Update for change in signature | |
6763 | of diagnostic_set_info. | |
6764 | * c-errors.c (pedwarn_c99): Likewise. | |
6765 | (pedwarn_c90): Likewise. | |
6766 | * c-objc-common.c (c_tree_printer): Update for new "caret_p" param | |
6767 | for textinfo::set_location. | |
6768 | ||
7a5e4956 CP |
6769 | 2015-11-05 Cesar Philippidis <cesar@codesourcery.com> |
6770 | Thomas Schwinge <thomas@codesourcery.com> | |
6771 | James Norris <jnorris@codesourcery.com> | |
6772 | ||
6773 | * c-parser.c (c_parser_omp_clause_name): Add support for | |
6774 | PRAGMA_OACC_CLAUSE_INDEPENDENT and PRAGMA_OACC_CLAUSE_TILE. | |
6775 | (c_parser_omp_clause_default): Add is_oacc argument. Handle | |
6776 | default(none) in OpenACC. | |
6777 | (c_parser_oacc_shape_clause): Allow pointer variables as gang static | |
6778 | arguments. | |
6779 | (c_parser_oacc_clause_tile): New function. | |
6780 | (c_parser_oacc_all_clauses): Add support for OMP_CLAUSE_DEFAULT, | |
6781 | OMP_CLAUSE_INDEPENDENT and OMP_CLAUSE_TILE. | |
6782 | (OACC_LOOP_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_{PRIVATE,INDEPENDENT, | |
6783 | TILE}. | |
6784 | (OACC_KERNELS_MASK): Add PRAGMA_OACC_CLAUSE_DEFAULT. | |
6785 | (OACC_PARALLEL_MASK): Add PRAGMA_OACC_CLAUSE_{DEFAULT,PRIVATE, | |
6786 | FIRSTPRIVATE}. | |
6787 | (c_parser_omp_all_clauses): Update call to c_parser_omp_clause_default. | |
6788 | (c_parser_oacc_update): Update the error message for missing clauses. | |
6789 | * c-typeck.c (c_finish_omp_clauses): Add support for OMP_CLAUSE_TILE | |
6790 | and OMP_CLAUSE_INDEPENDENT. | |
6791 | ||
bfcfbfa0 MP |
6792 | 2015-11-05 Marek Polacek <polacek@redhat.com> |
6793 | ||
6794 | PR c/68090 | |
6795 | * c-parser.c (c_parser_postfix_expression_after_paren_type): Don't | |
6796 | deal with pre-evaluation on invalid types. | |
6797 | ||
e01d41e5 JJ |
6798 | 2015-11-05 Jakub Jelinek <jakub@redhat.com> |
6799 | Ilya Verbin <ilya.verbin@intel.com> | |
6800 | ||
6801 | * c-parser.c: Include context.h and gimple-expr.h. | |
6802 | (c_parser_omp_clause_schedule): Parse schedule modifiers, diagnose | |
6803 | monotonic together with nonmonotonic. | |
6804 | (c_parser_omp_for_loop): Call c_omp_check_loop_iv. Call add_stmt here. | |
6805 | (OMP_DISTRIBUTE_CLAUSE_MASK): Add lastprivate clause. | |
6806 | (c_parser_omp_target_data, c_parser_omp_target_enter_data, | |
6807 | c_parser_omp_target_exit_data): Allow GOMP_MAP_ALWAYS_POINTER. | |
6808 | (c_parser_omp_target): Likewise. Evaluate num_teams and thread_limit | |
6809 | expressions on combined target teams before the target. | |
6810 | (c_parser_omp_declare_target): If decl has "omp declare target" or | |
6811 | "omp declare target link" attribute, and cgraph or varpool node already | |
6812 | exists, then set corresponding flags. Call c_finish_omp_clauses | |
6813 | in the parenthesized extended-list syntax case. | |
6814 | * c-decl.c (c_decl_attributes): Don't diagnose block scope vars inside | |
6815 | declare target. | |
6816 | * c-typeck.c (handle_omp_array_sections_1): Allow non-zero low-bound | |
6817 | on OMP_CLAUSE_REDUCTION array sections. | |
6818 | (handle_omp_array_sections): Encode low-bound into the MEM_REF, either | |
6819 | into the constant offset, or for variable low-bound using | |
6820 | POINTER_PLUS_EXPR. For structure element based array sections use | |
6821 | GOMP_MAP_ALWAYS_POINTER instead of GOMP_MAP_FIRSTPRIVATE_POINTER. | |
6822 | (c_finish_omp_clauses): Drop generic_field_head, structure | |
6823 | elements are now always mapped even as array section bases, | |
6824 | diagnose same var in data sharing and mapping clauses. Diagnose if | |
6825 | linear step on declare simd is neither a constant nor a uniform | |
6826 | parameter. Look through POINTER_PLUS_EXPR for array section | |
6827 | reductions. Diagnose the same var or function appearing multiple | |
6828 | times on the same directive. Fix up wording for the to clause if t | |
6829 | is neither a FUNCTION_DECL nor a VAR_DECL. Diagnose nonmonotonic | |
6830 | modifier on kinds other than dynamic or guided or nonmonotonic | |
6831 | modifier together with ordered clause. | |
6832 | ||
4bf9e5a8 TS |
6833 | 2015-11-03 Thomas Schwinge <thomas@codesourcery.com> |
6834 | Chung-Lin Tang <cltang@codesourcery.com> | |
6835 | ||
6836 | * c-parser.c (c_parser_omp_construct): Handle PRAGMA_OACC_ATOMIC. | |
6837 | ||
2adfab87 AM |
6838 | 2015-10-29 Andrew MacLeod <amacleod@redhat.com> |
6839 | ||
6840 | * c-array-notation.c: Reorder #include's and remove duplicates. | |
6841 | * c-aux-info.c: Likewise. | |
6842 | * c-convert.c: Likewise. | |
6843 | * c-decl.c: Likewise. | |
6844 | * c-errors.c: Likewise. | |
6845 | * c-lang.c: Likewise. | |
6846 | * c-objc-common.c: Likewise. | |
6847 | * c-parser.c: Likewise. | |
6848 | * c-typeck.c: Likewise. | |
6849 | ||
e922069e JW |
6850 | 2015-10-26 Jim Wilson <jim.wilson@linaro.org> |
6851 | ||
6852 | PR debug/66068 | |
6853 | * c-typeck.c (c_build_qualified_type): Clear C_TYPE_INCOMPLETE_VARS | |
6854 | after calling build_qualified_type. | |
6855 | ||
765dd391 CP |
6856 | 2015-10-27 Cesar Philippidis <cesar@codesourcery.com> |
6857 | Thomas Schwinge <thomas@codesourcery.com> | |
6858 | James Norris <jnorris@codesourcery.com> | |
6859 | Joseph Myers <joseph@codesourcery.com> | |
6860 | Julian Brown <julian@codesourcery.com> | |
6861 | Bernd Schmidt <bschmidt@redhat.com> | |
6862 | ||
6863 | * c-parser.c (c_parser_oacc_shape_clause): New. | |
6864 | (c_parser_oacc_simple_clause): New. | |
6865 | (c_parser_oacc_all_clauses): Add auto, gang, seq, vector, worker. | |
6866 | (OACC_LOOP_CLAUSE_MASK): Add gang, worker, vector, auto, seq. | |
6867 | ||
88bae6f4 TS |
6868 | 2015-10-27 Thomas Schwinge <thomas@codesourcery.com> |
6869 | James Norris <jnorris@codesourcery.com> | |
6870 | Cesar Philippidis <cesar@codesourcery.com> | |
6871 | ||
6872 | PR c/64765 | |
6873 | PR c/64880 | |
6874 | * c-parser.c (c_parser_oacc_loop): Add mask, cclauses formal | |
6875 | parameters, and handle these. Adjust all users. | |
6876 | (c_parser_oacc_kernels, c_parser_oacc_parallel): Merge functions | |
6877 | into... | |
6878 | (c_parser_oacc_kernels_parallel): ... this new function. Adjust | |
6879 | all users. | |
6880 | * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels): Don't | |
6881 | declare functions. | |
6882 | (c_finish_omp_construct): Declare function. | |
6883 | * c-typeck.c (c_finish_oacc_parallel, c_finish_oacc_kernels): | |
6884 | Merge functions into... | |
6885 | (c_finish_omp_construct): ... this new function. | |
6886 | ||
a8fc2579 RB |
6887 | 2015-10-22 Richard Biener <rguenther@suse.de> |
6888 | ||
6889 | * c-typeck.c (c_finish_omp_clauses): Properly convert operands | |
6890 | before folding a MINUS_EXPR. | |
6891 | ||
e9122ef6 MP |
6892 | 2015-10-21 Marek Polacek <polacek@redhat.com> |
6893 | ||
6894 | PR c/68024 | |
6895 | * c-decl.c (start_function): Warn about vararg functions without | |
6896 | a prototype. | |
6897 | ||
9f47c7e5 IE |
6898 | 2015-10-21 Ilya Enkovich <enkovich.gnu@gmail.com> |
6899 | ||
6900 | * c-typeck.c (build_conditional_expr): Use boolean vector | |
6901 | type for vector comparison. | |
6902 | (build_vec_cmp): New. | |
6903 | (build_binary_op): Use build_vec_cmp for comparison. | |
6904 | ||
fa60eeb9 MP |
6905 | 2015-10-20 Marek Polacek <polacek@redhat.com> |
6906 | ||
6907 | * c-parser.c (is_cilkplus_vector_p): Don't define here. | |
6908 | ||
2c7020eb MP |
6909 | 2015-10-20 Marek Polacek <polacek@redhat.com> |
6910 | ||
6911 | PR c/67964 | |
6912 | * c-parser.c (c_parser_attributes): Break out of the loop if the | |
6913 | token after an attribute isn't a comma. | |
6914 | ||
d9a6bd32 JJ |
6915 | 2015-10-13 Jakub Jelinek <jakub@redhat.com> |
6916 | Aldy Hernandez <aldyh@redhat.com> | |
6917 | ||
6918 | * c-parser.c (c_parser_pragma): Handle PRAGMA_OMP_ORDERED here. | |
6919 | (c_parser_omp_clause_name): Handle OpenMP 4.5 clauses. | |
6920 | (c_parser_omp_variable_list): Handle structure elements for | |
6921 | map, to and from clauses. Handle array sections in reduction | |
6922 | clause. Formatting fixes. | |
6923 | (c_parser_omp_clause_if): Add IS_OMP argument, handle parsing of | |
6924 | if clause modifiers. | |
6925 | (c_parser_omp_clause_num_tasks, c_parser_omp_clause_grainsize, | |
6926 | c_parser_omp_clause_priority, c_parser_omp_clause_hint, | |
6927 | c_parser_omp_clause_defaultmap, c_parser_omp_clause_use_device_ptr, | |
6928 | c_parser_omp_clause_is_device_ptr): New functions. | |
6929 | (c_parser_omp_clause_ordered): Parse optional parameter. | |
6930 | (c_parser_omp_clause_reduction): Handle array reductions. | |
6931 | (c_parser_omp_clause_schedule): Parse optional simd modifier. | |
6932 | (c_parser_omp_clause_nogroup, c_parser_omp_clause_orderedkind): New | |
6933 | functions. | |
6934 | (c_parser_omp_clause_linear): Parse linear clause modifiers. | |
6935 | (c_parser_omp_clause_depend_sink): New function. | |
6936 | (c_parser_omp_clause_depend): Parse source/sink depend kinds. | |
6937 | (c_parser_omp_clause_map): Parse release/delete map kinds and | |
6938 | optional always modifier. | |
6939 | (c_parser_oacc_all_clauses): Adjust c_parser_omp_clause_if | |
6940 | and c_finish_omp_clauses callers. | |
6941 | (c_parser_omp_all_clauses): Likewise. Parse OpenMP 4.5 clauses. | |
6942 | Parse "to" as OMP_CLAUSE_TO_DECLARE if on declare target directive. | |
6943 | (c_parser_oacc_cache): Adjust c_finish_omp_clauses caller. | |
6944 | (OMP_CRITICAL_CLAUSE_MASK): Define. | |
6945 | (c_parser_omp_critical): Parse critical clauses. | |
6946 | (c_parser_omp_for_loop): Handle doacross loops, adjust | |
6947 | c_finish_omp_for and c_finish_omp_clauses callers. | |
6948 | (OMP_SIMD_CLAUSE_MASK): Add simdlen clause. | |
6949 | (c_parser_omp_simd): Allow ordered clause if it has no parameter. | |
6950 | (OMP_FOR_CLAUSE_MASK): Add linear clause. | |
6951 | (c_parser_omp_for): Disallow ordered clause when combined with | |
6952 | distribute. Disallow linear clause when combined with distribute | |
6953 | and not combined with simd. | |
6954 | (OMP_ORDERED_CLAUSE_MASK, OMP_ORDERED_DEPEND_CLAUSE_MASK): Define. | |
6955 | (c_parser_omp_ordered): Add CONTEXT argument, remove LOC argument, | |
6956 | parse clauses and if depend clause is found, don't parse a body. | |
6957 | (c_parser_omp_parallel): Disallow copyin clause on target parallel. | |
6958 | Allow target parallel without for after it. | |
6959 | (OMP_TASK_CLAUSE_MASK): Add priority clause. | |
6960 | (OMP_TARGET_DATA_CLAUSE_MASK): Add use_device_ptr clause. | |
6961 | (c_parser_omp_target_data): Diagnose no map clauses or clauses with | |
6962 | invalid kinds. | |
6963 | (OMP_TARGET_UPDATE_CLAUSE_MASK): Add depend and nowait clauses. | |
6964 | (OMP_TARGET_ENTER_DATA_CLAUSE_MASK, | |
6965 | OMP_TARGET_EXIT_DATA_CLAUSE_MASK): Define. | |
6966 | (c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): New | |
6967 | functions. | |
6968 | (OMP_TARGET_CLAUSE_MASK): Add depend, nowait, private, firstprivate, | |
6969 | defaultmap and is_device_ptr clauses. | |
6970 | (c_parser_omp_target): Parse target parallel and target simd. Set | |
6971 | OMP_TARGET_COMBINED on combined constructs. Parse target enter data | |
6972 | and target exit data. Diagnose invalid map kinds. | |
6973 | (OMP_DECLARE_TARGET_CLAUSE_MASK): Define. | |
6974 | (c_parser_omp_declare_target): Parse OpenMP 4.5 forms of this | |
6975 | construct. | |
6976 | (c_parser_omp_declare_reduction): Use STRIP_NOPS when checking for | |
6977 | &omp_priv. | |
6978 | (OMP_TASKLOOP_CLAUSE_MASK): Define. | |
6979 | (c_parser_omp_taskloop): New function. | |
6980 | (c_parser_omp_construct): Don't handle PRAGMA_OMP_ORDERED here, | |
6981 | handle PRAGMA_OMP_TASKLOOP. | |
6982 | (c_parser_cilk_for): Adjust c_finish_omp_clauses callers. | |
6983 | * c-tree.h (c_finish_omp_clauses): Add two new arguments. | |
6984 | * c-typeck.c (handle_omp_array_sections_1): Fix comment typo. | |
6985 | Add IS_OMP argument, handle structure element bases, diagnose | |
6986 | bitfields, pass IS_OMP recursively, diagnose known zero length | |
6987 | array sections in depend clauses, handle array sections in reduction | |
6988 | clause, diagnose negative length even for pointers. | |
6989 | (handle_omp_array_sections): Add IS_OMP argument, use auto_vec for | |
6990 | types, pass IS_OMP down to handle_omp_array_sections_1, handle | |
6991 | array sections in reduction clause, set | |
6992 | OMP_CLAUSE_MAP_MAYBE_ZERO_LENGTH_ARRAY_SECTION if map could be zero | |
6993 | length array section, use GOMP_MAP_FIRSTPRIVATE_POINTER for IS_OMP. | |
6994 | (c_finish_omp_clauses): Add IS_OMP and DECLARE_SIMD arguments. | |
6995 | Handle new OpenMP 4.5 clauses and new restrictions for the old ones. | |
6996 | ||
21ba0cea MP |
6997 | 2015-10-06 Marek Polacek <polacek@redhat.com> |
6998 | ||
6999 | * c-parser.c (c_parser_statement_after_labels): Use | |
7000 | protected_set_expr_location. | |
7001 | (c_parser_omp_clause_num_gangs): Likewise. | |
7002 | (c_parser_omp_clause_num_threads): Likewise. | |
7003 | (c_parser_omp_clause_num_workers): Likewise. | |
7004 | (c_parser_omp_clause_vector_length): Likewise. | |
7005 | (c_parser_omp_clause_num_teams): Likewise. | |
7006 | (c_parser_omp_clause_thread_limit): Likewise. | |
7007 | * c-typeck.c (build_c_cast): Likewise. | |
7008 | (c_cast_expr): Likewise. | |
7009 | ||
624d31fe RS |
7010 | 2015-10-05 Richard Sandiford <richard.sandiford@arm.com> |
7011 | ||
7012 | * c-typeck.c (c_tree_equal): Use real_equal instead of | |
7013 | REAL_VALUES_EQUAL. | |
7014 | ||
b8fd7909 JM |
7015 | 2015-10-04 Jason Merrill <jason@redhat.com> |
7016 | ||
7017 | * c-parser.c (c_lex_one_token): Handle @synchronized. | |
7018 | * c-decl.c (match_builtin_function_types): A declaration of a built-in | |
7019 | can change whether the function is transaction_safe. | |
7020 | ||
1c7485af MP |
7021 | 2015-10-02 Marek Polacek <polacek@redhat.com> |
7022 | ||
7023 | PR c/67730 | |
7024 | * c-typeck.c (convert_for_assignment): Use the expansion point | |
7025 | location throughout. | |
7026 | ||
3e3b8d63 MP |
7027 | 2015-10-02 Marek Polacek <polacek@redhat.com> |
7028 | ||
7029 | PR c/64249 | |
7030 | * c-parser.c (c_parser_statement_after_labels): Add CHAIN parameter | |
7031 | and pass it down to c_parser_if_statement. | |
7032 | (c_parser_else_body): Add CHAIN parameter and pass it down to | |
7033 | c_parser_statement_after_labels. | |
7034 | (c_parser_if_statement): Add CHAIN parameter. Add code to warn about | |
7035 | duplicated if-else-if conditions. | |
7036 | ||
aabef2de MP |
7037 | 2015-10-01 Marek Polacek <polacek@redhat.com> |
7038 | ||
7039 | * c-typeck.c (convert_for_assignment): Improve commentary. | |
7040 | ||
de8ddd5f MP |
7041 | 2015-09-30 Marek Polacek <polacek@redhat.com> |
7042 | ||
7043 | PR c/67730 | |
7044 | * c-typeck.c (c_finish_return): Use the expansion point location for | |
7045 | certain "return with value" warnings. | |
7046 | ||
c4914de6 MLI |
7047 | 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org> |
7048 | ||
7049 | * c-parser.c (pragma_lex): Add loc argument. | |
7050 | ||
0e36f5c7 MP |
7051 | 2015-09-15 Marek Polacek <polacek@redhat.com> |
7052 | ||
7053 | PR c/67580 | |
7054 | * c-decl.c (tag_exists_p): New function. | |
7055 | * c-parser.c (c_parser_declaration_or_fndef): Give a hint when | |
7056 | struct/union/enum keywords are missing. | |
7057 | * c-tree.h (tag_exists_p): Declare. | |
7058 | ||
2f3bb934 MP |
7059 | 2015-09-15 Marek Polacek <polacek@redhat.com> |
7060 | ||
7061 | * c-decl.c (lookup_label): Return NULL_TREE instead of 0. | |
7062 | (lookup_tag): Change the type of THISLEVEL_ONLY to bool. | |
7063 | Return NULL_TREE instead of 0. | |
7064 | (lookup_name): Return NULL_TREE instead of 0. | |
7065 | (lookup_name_in_scope): Likewise. | |
7066 | (shadow_tag_warned): Use true instead of 1 and NULL_TREE instead of 0. | |
7067 | (parser_xref_tag): Use false instead of 0. | |
7068 | (start_struct): Use true instead of 1. | |
7069 | (start_enum): Use true instead of 1 and NULL_TREE instead of 0. | |
7070 | ||
aa256c4a MP |
7071 | 2015-09-14 Marek Polacek <polacek@redhat.com> |
7072 | ||
7073 | * c-typeck.c (set_nonincremental_init_from_string): Use | |
7074 | HOST_WIDE_INT_M1U when shifting a negative value. | |
7075 | ||
dbb68221 MW |
7076 | 2015-09-09 Mark Wielaard <mjw@redhat.com> |
7077 | ||
7078 | * c-typeck.c (build_binary_op): Check and warn when nonnull arg | |
7079 | parm against NULL. | |
7080 | ||
a8a098ac JJ |
7081 | 2015-09-10 Jakub Jelinek <jakub@redhat.com> |
7082 | ||
7083 | PR c/67502 | |
7084 | * c-parser.c (c_parser_omp_for_loop): Emit DECL_EXPR stmts | |
7085 | into OMP_FOR_PRE_BODY rather than before the loop. | |
7086 | ||
f4b189d5 JJ |
7087 | 2015-09-09 Jakub Jelinek <jakub@redhat.com> |
7088 | ||
0bb99c11 JJ |
7089 | PR c/67501 |
7090 | * c-parser.c (c_parser_oacc_all_clauses, | |
7091 | c_parser_omp_all_clauses): Remove invalid clause from | |
7092 | list of clauses even if parser->error is set. | |
7093 | ||
fce5e5e3 JJ |
7094 | PR c/67500 |
7095 | * c-parser.c (c_parser_omp_clause_aligned, | |
7096 | c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen): Fix up | |
7097 | test for errors. | |
7098 | * c-decl.c (temp_pop_parm_decls): Allow b->decl equal to | |
7099 | error_mark_node. | |
7100 | ||
f4b189d5 JJ |
7101 | PR c/67495 |
7102 | * c-parser.c (c_parser_omp_atomic): Use c_parser_cast_expression | |
7103 | instead of c_parser_unary_expression. If the result is !lvalue_p, | |
7104 | wrap the result of c_fully_fold into NON_LVALUE_EXPR. | |
7105 | ||
b2aaf235 MP |
7106 | 2015-09-04 Marek Polacek <polacek@redhat.com> |
7107 | ||
7108 | PR sanitizer/67279 | |
7109 | * c-typeck.c (build_binary_op): Don't instrument static initializers. | |
7110 | ||
1807ffc1 MS |
7111 | 2015-09-03 Martin Sebor <msebor@redhat.com> |
7112 | ||
7113 | PR c/66516 | |
8b652e65 JJ |
7114 | * c-typeck.c (convert_arguments, parser_build_unary_op, |
7115 | build_conditional_expr, c_cast_expr, convert_for_assignment, | |
7116 | build_binary_op, _objc_common_truthvalue_conversion): Call | |
1807ffc1 MS |
7117 | reject_gcc_builtin. |
7118 | (c_decl_implicit): Define. | |
7119 | ||
d04ff417 MP |
7120 | 2015-09-02 Marek Polacek <polacek@redhat.com> |
7121 | ||
7122 | PR c/67432 | |
7123 | * c-parser.c (c_parser_enum_specifier): Give a better error for | |
7124 | an empty enum. | |
7125 | ||
a79683d5 TS |
7126 | 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org> |
7127 | ||
7128 | * c-aux-info.c, c-parser.c, c-tree.h: Remove useless typedefs. | |
7129 | ||
191a6b94 MP |
7130 | 2015-08-12 Marek Polacek <polacek@redhat.com> |
7131 | ||
7132 | * c-decl.c (grokdeclarator): Call error_at instead of error and pass | |
7133 | LOC to it. | |
7134 | ||
420a9d9b MP |
7135 | 2015-08-03 Marek Polacek <polacek@redhat.com> |
7136 | ||
7137 | PR c/67088 | |
7138 | * c-decl.c (check_bitfield_type_and_width): Add location parameter. | |
7139 | Use it. | |
7140 | (grokdeclarator): Pass LOC down to check_bitfield_type_and_width. | |
7141 | ||
992118a1 PP |
7142 | 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org> |
7143 | ||
7144 | * c-parser.c (c_parser_if_body): Take token_indent_info | |
7145 | argument. Call warn_for_misleading_indentation even when the | |
7146 | body is a semicolon. Extract token_indent_infos corresponding | |
7147 | to the guard, body and next tokens. Adjust call to | |
7148 | warn_for_misleading_indentation accordingly. | |
7149 | (c_parser_else_body): Likewise. | |
7150 | (c_parser_if_statement): Likewise. | |
7151 | (c_parser_while_statement): Likewise. | |
7152 | (c_parser_for_statement): Likewise. | |
7153 | ||
46308474 LFSM |
7154 | 2015-07-28 Luis Felipe Strano Moraes <luis.strano@gmail.com> |
7155 | Manuel López-Ibáñez <manu@gcc.gnu.org> | |
7156 | ||
7157 | * c-decl.c (get_parm_info): Remove static var. Update warning | |
7158 | message. | |
7159 | ||
05b28fd6 MP |
7160 | 2015-07-27 Marek Polacek <polacek@redhat.com> |
7161 | ||
7162 | PR c++/66555 | |
7163 | PR c/54979 | |
7164 | * c-typeck.c (parser_build_binary_op): Call warn_tautological_cmp. | |
7165 | ||
451b5e48 MP |
7166 | 2015-07-20 Marek Polacek <polacek@redhat.com> |
7167 | ||
7168 | PR c++/55095 | |
7169 | * c-typeck.c (digest_init): Pass OPT_Wpedantic to pedwarn_init. | |
7170 | (build_binary_op): Warn about left shift overflows. | |
7171 | ||
1916bcb5 AM |
7172 | 2015-07-09 Andrew MacLeod <amacleod@redhat.com> |
7173 | ||
7174 | * c-array-notation.c: Adjust includes for flags.h changes. | |
7175 | * c-objc-common.c: Likewise. | |
7176 | ||
c7131fb2 AM |
7177 | 2015-07-07 Andrew MacLeod <amacleod@redhat.com> |
7178 | ||
7179 | * c-array-notation.c: Adjust includes. | |
7180 | * c-aux-info.c: Likewise. | |
7181 | * c-convert.c: Likewise. | |
7182 | * c-decl.c: Likewise. | |
7183 | * c-errors.c: Likewise. | |
7184 | * c-lang.c: Likewise. | |
7185 | * c-objc-common.c: Likewise. | |
7186 | * c-parser.c: Likewise. | |
7187 | * c-typeck.c: Likewise. | |
7188 | ||
da2e71c9 MLI |
7189 | 2015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org> |
7190 | ||
7191 | PR fortran/66605 | |
7192 | * c-decl.c (finish_function): Call do_warn_unused_parameter. | |
7193 | ||
b155cfd9 MP |
7194 | 2015-06-29 Marek Polacek <polacek@redhat.com> |
7195 | ||
7196 | PR c/66322 | |
7197 | * c-typeck.c (struct c_switch): Add BOOL_COND_P and OUTSIDE_RANGE_P. | |
7198 | (c_start_case): Set BOOL_COND_P and OUTSIDE_RANGE_P. Don't warn | |
7199 | about -Wswitch-bool here. | |
7200 | (do_case): Update c_add_case_label call. | |
7201 | (c_finish_case): Update c_do_switch_warnings call. | |
7202 | ||
31521951 MP |
7203 | 2015-06-27 Marek Polacek <polacek@redhat.com> |
7204 | ||
7205 | * c-typeck.c: Use VECTOR_TYPE_P throughout. | |
7206 | ||
22d03525 MP |
7207 | 2015-06-26 Marek Polacek <polacek@redhat.com> |
7208 | ||
7209 | * c-array-notation.c (fix_builtin_array_notation_fn): Use | |
7210 | INDIRECT_REF_P. | |
7211 | * c-typeck.c (array_to_pointer_conversion): Likewise. | |
7212 | (build_unary_op): Likewise. | |
7213 | (c_finish_return): Likewise. | |
7214 | ||
f0889939 AM |
7215 | 2015-06-25 Andrew MacLeod <amacleod@redhat.com> |
7216 | ||
7217 | * c-decl.c: Remove ipa-ref.h and plugin-api.h from include list. | |
7218 | * c-parser.c: Likewise. | |
7219 | ||
8d67ee55 RS |
7220 | 2015-06-25 Richard Sandiford <richard.sandiford@arm.com> |
7221 | ||
7222 | * c-decl.c (detect_field_duplicates_hash): Use nofree_ptr_hash | |
7223 | instead of pointer_hash. | |
7224 | (detect_field_duplicates): Likewise. | |
7225 | ||
0ae9bd27 MP |
7226 | 2015-06-25 Marek Polacek <polacek@redhat.com> |
7227 | ||
7228 | * c-array-notation.c: Use VAR_P throughout. | |
7229 | * c-decl.c: Likewise. | |
7230 | * c-objc-common.c: Likewise. | |
7231 | * c-parser.c: Likewise. | |
7232 | * c-typeck.c: Likewise. | |
7233 | ||
62f9079a MP |
7234 | 2015-06-25 Marek Polacek <polacek@redhat.com> |
7235 | ||
7236 | * c-decl.c: Use is_global_var throughout. | |
7237 | * c-parser.c: Likewise. | |
7238 | * c-typeck.c: Likewise. | |
7239 | ||
abb226c9 AM |
7240 | 2015-06-17 Andrew MacLeod <amacleod@redhat.com> |
7241 | ||
7242 | * c-array-notation.c: Do not include input.h, line-map.h or is-a.h. | |
7243 | * c-aux-info.c: Likewise. | |
7244 | * c-convert.c: Likewise. | |
7245 | * c-decl.c: Likewise. | |
7246 | * c-errors.c: Likewise. | |
7247 | * c-lang.c: Likewise. | |
7248 | * c-objc-common.c: Likewise. | |
7249 | * c-parser.c: Likewise. | |
7250 | * c-typeck.c: Likewise. | |
7251 | ||
8cbababc JH |
7252 | 2015-06-11 Jan Hubicka <hubicka@ucw.cz> |
7253 | ||
7254 | PR middle-end/66325 | |
7255 | * c-decl.c (start_enum): Set TYPE_PACKED consistently among type | |
7256 | variants. | |
7257 | ||
a0349665 PMR |
7258 | 2015-06-11 Pierre-Marie de Rodat <derodat@adacore.com> |
7259 | ||
7260 | * c-decl.c (pop_scope): Register the main translation unit | |
7261 | through the new debug hook. | |
7262 | ||
13fdf2e2 AM |
7263 | 2015-06-08 Andrew MacLeod <amacleod@redhat.com> |
7264 | ||
7265 | * c-array-notation.c : Adjust include files. | |
7266 | * c-aux-info.c : Likewise. | |
7267 | * c-convert.c : Likewise. | |
7268 | * c-decl.c : Likewise. | |
7269 | * c-errors.c : Likewise. | |
7270 | * c-lang.c : Likewise. | |
7271 | * c-lang.h : Likewise. | |
7272 | * c-objc-common.c : Likewise. | |
7273 | * c-parser.c : Likewise. | |
7274 | * c-typeck.c : Likewise. | |
7275 | ||
d7438551 AH |
7276 | 2015-06-05 Aldy Hernandez <aldyh@redhat.com> |
7277 | ||
7278 | * c-decl.c (finish_struct): Save C_TYPE_INCOMPLETE_VARS and | |
7279 | immediately clobber it. | |
7280 | (c_write_global_declarations_1): Remove call to | |
7281 | check_global_declaration_1. | |
7282 | (c_write_global_declarations_2): Remove. | |
7283 | (c_write_final_cleanups): Rename from c_write_global_declarations. | |
7284 | Remove call to finalize_compilation_unit. | |
7285 | Remove calls to debugging hooks. | |
7286 | * c-objc-common.c: Adjust comment for c_warn_unused_global_decl. | |
7287 | * c-objc-common.h: Remove LANG_HOOKS_WRITE_GLOBALS. | |
7288 | * c-tree.h: Remove c_write_global_declarations. | |
7289 | ||
ecb9f223 AM |
7290 | 2015-06-04 Andrew MacLeod <amacleod@redhat.com> |
7291 | ||
7292 | * c-array-notation.c: Adjust includes for restructured coretypes.h. | |
7293 | * c-aux-info.c: Likewise. | |
7294 | * c-convert.c: Likewise. | |
7295 | * c-decl.c: Likewise. | |
7296 | * c-errors.c: Likewise. | |
7297 | * c-lang.c: Likewise. | |
7298 | * c-objc-common.c: Likewise. | |
7299 | * c-parser.c: Likewise. | |
7300 | * c-typeck.c: Likewise. | |
7301 | ||
9482b620 MP |
7302 | 2015-06-04 Marek Polacek <polacek@redhat.com> |
7303 | ||
7304 | PR c/66341 | |
7305 | * c-typeck.c (build_c_cast): Wrap VALUE into NON_LVALUE_EXPR if | |
7306 | it is a lvalue. | |
7307 | ||
bc51ace3 PK |
7308 | 2015-06-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
7309 | ||
7310 | * c-decl.c (warn_cxx_compat_finish_struct): New parameters code, record_loc. | |
7311 | Warn for empty struct. | |
7312 | (finish_struct): Pass TREE_CODE(t) and loc to warn_cxx_compat_finish_struct. | |
7313 | ||
ea5b45b6 AT |
7314 | 2015-06-02 Andres Tiraboschi <andres.tiraboschi@tallertechnologies.com> |
7315 | ||
7316 | * c-decl.c (start_function): Call plugin before parsing. | |
7317 | (finish_function): Call plugin after parsing. | |
7318 | ||
c2d47482 PK |
7319 | 2015-06-02 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> |
7320 | ||
7321 | PR c/49551 | |
7322 | * c-decl.c (merge_decls): Merge DECL_COMMON. | |
7323 | ||
a95492ab JW |
7324 | 2015-05-22 Jim Wilson <jim.wilson@linaro.org> |
7325 | ||
7326 | * Make-lang.in (check_gcc_pallelize): Define. | |
7327 | ||
fd5c817a MP |
7328 | 2015-05-22 Marek Polacek <polacek@redhat.com> |
7329 | ||
7330 | PR c/47043 | |
7331 | * c-parser.c (c_parser_enum_specifier): Parse and apply enumerator | |
7332 | attributes. | |
7333 | ||
c7b70a3c MP |
7334 | 2015-05-21 Marek Polacek <polacek@redhat.com> |
7335 | ||
7336 | * c-typeck.c (inform_declaration): Use DECL_IS_BUILTIN instead of | |
7337 | DECL_BUILT_IN. | |
7338 | ||
21b634ae MP |
7339 | 2015-05-20 Marek Polacek <polacek@redhat.com> |
7340 | ||
7341 | * c-decl.c: Use VAR_OR_FUNCTION_DECL_P throughout. | |
7342 | * c-typeck.c: Likewise. | |
7343 | ||
296a8c2f MP |
7344 | 2015-05-19 Marek Polacek <polacek@redhat.com> |
7345 | ||
7346 | * c-typeck.c (start_init): Use AGGREGATE_TYPE_P. | |
7347 | ||
41b37d5e JJ |
7348 | 2015-05-19 Jakub Jelinek <jakub@redhat.com> |
7349 | ||
7350 | PR middle-end/66199 | |
7351 | * c-parser.c (c_parser_omp_for_loop): Don't add | |
7352 | OMP_CLAUSE_SHARED to OMP_PARALLEL_CLAUSES when moving | |
7353 | OMP_CLAUSE_LASTPRIVATE clause to OMP_FOR_CLAUSES. | |
7354 | (c_parser_omp_teams): Set OMP_TEAMS_COMBINED for combined | |
7355 | constructs. | |
7356 | ||
fab27f52 MM |
7357 | 2015-05-19 Mikhail Maltsev <maltsevm@gmail.com> |
7358 | ||
7359 | * c-typeck.c (build_array_ref): Use std::swap instead of explicit | |
296a8c2f | 7360 | swaps. |
fab27f52 | 7361 | |
40de31cf MLI |
7362 | 2015-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org> |
7363 | ||
7364 | PR fortran/44054 | |
7365 | * c-objc-common.c (c_tree_printer): Replace locus pointer with | |
7366 | accessor function. | |
7367 | ||
3aa3c9fc MP |
7368 | 2015-05-14 Marek Polacek <polacek@redhat.com> |
7369 | ||
7370 | PR c/66066 | |
7371 | PR c/66127 | |
7372 | * c-typeck.c (digest_init): Call pedwarn_init with OPT_Wpedantic | |
7373 | rather than with 0. | |
7374 | ||
c3388e62 DM |
7375 | 2015-05-12 David Malcolm <dmalcolm@redhat.com> |
7376 | ||
7377 | * c-parser.c (c_parser_if_body): Add param "if_loc", use it | |
7378 | to add a call to warn_for_misleading_indentation. | |
7379 | (c_parser_else_body): Likewise, adding param "else_loc". | |
7380 | (c_parser_if_statement): Check for misleading indentation. | |
7381 | (c_parser_while_statement): Likewise. | |
7382 | (c_parser_for_statement): Likewise. | |
7383 | ||
755e528f MP |
7384 | 2015-05-08 Marek Polacek <polacek@redhat.com> |
7385 | ||
7386 | PR c/64918 | |
7387 | * c-typeck.c (add_pending_init): Use OPT_Woverride_init_side_effects. | |
7388 | (output_init_element): Likewise. | |
7389 | ||
0173bd2a MP |
7390 | 2015-05-07 Marek Polacek <polacek@redhat.com> |
7391 | ||
7392 | PR c/65179 | |
7393 | * c-typeck.c (build_binary_op): Warn when left shifting a negative | |
7394 | value. | |
7395 | ||
9babc352 MP |
7396 | 2015-04-30 Marek Polacek <polacek@redhat.com> |
7397 | ||
7398 | * c-typeck.c (set_init_label): Call error_at instead of error and | |
7399 | pass LOC to it. | |
7400 | ||
ac9f18db MP |
7401 | * c-typeck.c (c_incomplete_type_error): Refactor to use %qT. Print |
7402 | the type of a decl. | |
7403 | ||
ec3fba51 MP |
7404 | * c-typeck.c (c_build_va_arg): Clarify the error message. |
7405 | ||
b811915d TS |
7406 | 2015-04-29 Thomas Schwinge <thomas@codesourcery.com> |
7407 | ||
7408 | * c-parser.c (c_parser_oacc_enter_exit_data): Use | |
7409 | OMP_STANDALONE_CLAUSES. | |
7410 | ||
f3075008 MP |
7411 | 2015-04-28 Marek Polacek <polacek@redhat.com> |
7412 | ||
7413 | * c-parser.c (c_parser_binary_expression): Remove duplicate line. | |
7414 | ||
4e81b788 MP |
7415 | 2015-04-28 Marek Polacek <polacek@redhat.com> |
7416 | ||
7417 | PR c/65901 | |
7418 | * c-typeck.c (c_build_va_arg): Require TYPE be a complete type. | |
7419 | ||
6c1db78e MP |
7420 | 2015-04-25 Marek Polacek <polacek@redhat.com> |
7421 | ||
7422 | PR c/52085 | |
7423 | * c-decl.c (finish_enum): Copy over TYPE_ALIGN. Also check for "mode" | |
7424 | attribute. | |
7425 | ||
5c4abbb8 MP |
7426 | 2015-04-23 Marek Polacek <polacek@redhat.com> |
7427 | ||
7428 | PR c/65345 | |
7429 | * c-decl.c (set_labels_context_r): New function. | |
7430 | (store_parm_decls): Call it via walk_tree_without_duplicates. | |
7431 | * c-typeck.c (convert_lvalue_to_rvalue): Use create_tmp_var_raw | |
7432 | instead of create_tmp_var. Build TARGET_EXPR instead of | |
7433 | COMPOUND_EXPR. | |
7434 | (build_atomic_assign): Use create_tmp_var_raw instead of | |
7435 | create_tmp_var. Build TARGET_EXPRs instead of MODIFY_EXPR. | |
7436 | ||
06aca1d5 IV |
7437 | 2015-04-20 Ilya Verbin <ilya.verbin@intel.com> |
7438 | ||
7439 | * c-parser.c (c_parser_oacc_enter_exit_data): Remove excess semicolon. | |
7440 | (c_parser_omp_target_update): Add missed %> to error_at (). | |
7441 | ||
8fba1830 BRF |
7442 | 2015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org> |
7443 | ||
7444 | PR target/55143 | |
7445 | * c-decl.c (c_default_pointer_mode): Remove definition. | |
7446 | * c-tree.h (c_default_pointer_mode): Remove declaration. | |
7447 | ||
62021f64 TB |
7448 | 2015-03-27 Tobias Burnus <burnus@net-b.de> |
7449 | ||
7450 | PR c/65586 | |
7451 | * c-parser.c (c_parser_skip_to_pragma_eol): Optionally, don't | |
7452 | error out. | |
7453 | (c_parser_omp_for, c_parser_omp_parallel, c_parser_omp_distribute, | |
7454 | c_parser_omp_teams, c_parser_omp_target, c_parser_omp_declare): | |
7455 | Update calls to not error for skipped omp pragmas with -fopenmp-simd. | |
7456 | ||
9b65e171 JJ |
7457 | 2015-03-19 Jakub Jelinek <jakub@redhat.com> |
7458 | ||
7459 | * c-decl.c (c_decl_attributes): Also add "omp declare target" | |
7460 | attribute for DECL_EXTERNAL VAR_DECLs. | |
7461 | ||
17958621 JJ |
7462 | 2015-03-11 Jakub Jelinek <jakub@redhat.com> |
7463 | ||
7464 | * c-parser.c (c_parse_init): Don't call xstrdup on get_identifier | |
7465 | argument. | |
7466 | ||
7ccb1a11 JJ |
7467 | 2015-03-10 Jakub Jelinek <jakub@redhat.com> |
7468 | ||
7469 | PR c/65120 | |
7470 | * c-typeck.c (parser_build_binary_op): Check for tcc_comparison | |
7471 | before preparing arguments to warn_logical_not_parentheses. | |
7472 | ||
01177669 JJ |
7473 | 2015-03-09 Jakub Jelinek <jakub@redhat.com> |
7474 | ||
7475 | PR c/65120 | |
7476 | * c-typeck.c (parser_build_binary_op): Don't warn for | |
7477 | !!x == y or !b == y where b is _Bool. | |
7478 | ||
802ac282 MP |
7479 | 2015-03-09 Marek Polacek <polacek@redhat.com> |
7480 | ||
7481 | * c-convert.c (convert): Make use of do_ubsan_in_current_function. | |
7482 | * c-decl.c (grokdeclarator): Likewise. | |
7483 | * c-typeck.c (build_binary_op): Likewise. | |
7484 | ||
e5165b60 MP |
7485 | 2015-02-27 Marek Polacek <polacek@redhat.com> |
7486 | ||
7487 | PR c/65228 | |
7488 | * c-decl.c (start_decl): Return NULL_TREE if decl is an error node. | |
7489 | ||
065d214c MP |
7490 | 2015-02-14 Marek Polacek <polacek@redhat.com> |
7491 | ||
7492 | PR c/64768 | |
7493 | * c-decl.c (grokdeclarator): Set the range of a flexible array member | |
7494 | declared through a typedef name. | |
7495 | ||
e5d9235b MP |
7496 | 2015-02-13 Marek Polacek <polacek@redhat.com> |
7497 | ||
7498 | PR c/65050 | |
7499 | * c-decl.c (grokdeclarator): Print also the type when giving | |
7500 | the error message about array's incomplete element type. | |
7501 | ||
fa01ffcc JJ |
7502 | 2015-02-11 Jakub Jelinek <jakub@redhat.com> |
7503 | ||
7504 | PR c/64824 | |
7505 | * c-parser.c (c_parser_binary_expression): Fix OpenMP stack[sp].prec | |
7506 | check in the POP macro. | |
7507 | ||
c3e38a03 MP |
7508 | 2015-02-09 Marek Polacek <polacek@redhat.com> |
7509 | ||
7510 | PR c/64856 | |
7511 | * c-typeck.c (process_init_element): Don't always wrap | |
7512 | COMPOUND_LITERAL_EXPR in a SAVE_EXPR in C99 mode when | |
7513 | initializing a range of elements. | |
7514 | ||
4886ec8e JJ |
7515 | 2015-02-04 Jakub Jelinek <jakub@redhat.com> |
7516 | ||
7517 | PR c/64824 | |
7518 | PR c/64868 | |
7519 | * c-parser.c (c_parser_omp_atomic): Handle RDIV_EXPR. | |
7520 | ||
c3e38a03 | 7521 | 2015-02-02 Bruno Loff <bruno.loff@gmail.com> |
a4bb6959 BL |
7522 | |
7523 | * c-parser.c (c_parser_declspecs): Call invoke_plugin_callbacks after | |
7524 | processing enum declaration. | |
7525 | ||
7b33f0c8 MP |
7526 | 2015-01-29 Marek Polacek <polacek@redhat.com> |
7527 | ||
7528 | PR c/64709 | |
7529 | * c-typeck.c (pop_init_level): If constructor_elements has | |
7530 | exactly one element with integer_zerop value, set constructor_zeroinit | |
7531 | to 1. Remove braces around warning_init call. | |
7532 | ||
dea63e49 JJ |
7533 | 2015-01-27 Jakub Jelinek <jakub@redhat.com> |
7534 | ||
7535 | PR c/64766 | |
7536 | * c-typeck.c (store_init_value): Don't overwrite DECL_INITIAL | |
7537 | of FUNCTION_DECLs with error_mark_node. | |
7538 | ||
d38f7dce JJ |
7539 | 2015-01-26 Jakub Jelinek <jakub@redhat.com> |
7540 | ||
7541 | PR c/64778 | |
7542 | * c-typeck.c (convert_arguments): Return -1 if there are | |
7543 | error_args, even if we've diagnosed too many arguments. | |
7544 | ||
cbf5d0e7 RB |
7545 | 2015-01-21 Richard Biener <rguenther@suse.de> |
7546 | ||
7547 | PR middle-end/64313 | |
7548 | * c-decl.c (merge_decls): Call set_builtin_decl_declared_p | |
7549 | for builtins the user declared correctly. | |
7550 | ||
41dbbb37 TS |
7551 | 2015-01-15 Thomas Schwinge <thomas@codesourcery.com> |
7552 | Bernd Schmidt <bernds@codesourcery.com> | |
7553 | Cesar Philippidis <cesar@codesourcery.com> | |
7554 | James Norris <jnorris@codesourcery.com> | |
7555 | Jakub Jelinek <jakub@redhat.com> | |
7556 | Ilmir Usmanov <i.usmanov@samsung.com> | |
7557 | ||
7558 | * c-parser.c: Include "gomp-constants.h". | |
7559 | (c_parser_omp_clause_map): Use enum gomp_map_kind instead of enum | |
7560 | omp_clause_map_kind. Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*. | |
7561 | Use OMP_CLAUSE_SET_MAP_KIND. | |
7562 | (c_parser_pragma): Handle PRAGMA_OACC_ENTER_DATA, | |
7563 | PRAGMA_OACC_EXIT_DATA, PRAGMA_OACC_UPDATE. | |
7564 | (c_parser_omp_construct): Handle PRAGMA_OACC_CACHE, | |
7565 | PRAGMA_OACC_DATA, PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, | |
7566 | PRAGMA_OACC_PARALLEL, PRAGMA_OACC_WAIT. | |
7567 | (c_parser_omp_clause_name): Handle "auto", "async", "copy", | |
7568 | "copyout", "create", "delete", "deviceptr", "gang", "host", | |
7569 | "num_gangs", "num_workers", "present", "present_or_copy", "pcopy", | |
7570 | "present_or_copyin", "pcopyin", "present_or_copyout", "pcopyout", | |
7571 | "present_or_create", "pcreate", "seq", "self", "vector", | |
7572 | "vector_length", "wait", "worker". | |
7573 | (OACC_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK) | |
7574 | (OACC_ENTER_DATA_CLAUSE_MASK, OACC_EXIT_DATA_CLAUSE_MASK) | |
7575 | (OACC_LOOP_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK) | |
7576 | (OACC_UPDATE_CLAUSE_MASK, OACC_WAIT_CLAUSE_MASK): New macros. | |
7577 | (c_parser_omp_variable_list): Handle OMP_CLAUSE__CACHE_. | |
7578 | (c_parser_oacc_wait_list, c_parser_oacc_data_clause) | |
7579 | (c_parser_oacc_data_clause_deviceptr) | |
7580 | (c_parser_omp_clause_num_gangs, c_parser_omp_clause_num_workers) | |
7581 | (c_parser_oacc_clause_async, c_parser_oacc_clause_wait) | |
7582 | (c_parser_omp_clause_vector_length, c_parser_oacc_all_clauses) | |
7583 | (c_parser_oacc_cache, c_parser_oacc_data, c_parser_oacc_kernels) | |
7584 | (c_parser_oacc_enter_exit_data, c_parser_oacc_loop) | |
7585 | (c_parser_oacc_parallel, c_parser_oacc_update) | |
7586 | (c_parser_oacc_wait): New functions. | |
7587 | * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels) | |
7588 | (c_finish_oacc_data): New prototypes. | |
7589 | * c-typeck.c: Include "gomp-constants.h". | |
7590 | (handle_omp_array_sections): Handle GOMP_MAP_FORCE_DEVICEPTR. Use | |
7591 | GOMP_MAP_* instead of OMP_CLAUSE_MAP_*. Use | |
7592 | OMP_CLAUSE_SET_MAP_KIND. | |
7593 | (c_finish_oacc_parallel, c_finish_oacc_kernels) | |
7594 | (c_finish_oacc_data): New functions. | |
7595 | (c_finish_omp_clauses): Handle OMP_CLAUSE__CACHE_, | |
7596 | OMP_CLAUSE_NUM_GANGS, OMP_CLAUSE_NUM_WORKERS, | |
7597 | OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_ASYNC, OMP_CLAUSE_WAIT, | |
7598 | OMP_CLAUSE_AUTO, OMP_CLAUSE_SEQ, OMP_CLAUSE_GANG, | |
7599 | OMP_CLAUSE_WORKER, OMP_CLAUSE_VECTOR, and OMP_CLAUSE_MAP's | |
7600 | GOMP_MAP_FORCE_DEVICEPTR. | |
7601 | ||
adfac8df JJ |
7602 | 2015-01-09 Michael Collison <michael.collison@linaro.org> |
7603 | ||
7604 | * c-array-notation.c: Include hash-set.h, machmode.h, | |
7605 | vec.h, double-int.h, input.h, alias.h, symtab.h, options.h | |
7606 | fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h. | |
7607 | * c-aux-info.c: Ditto. | |
7608 | * c-convert.c: Ditto. | |
7609 | * c-decl.c: Ditto. | |
7610 | * c-errors.c: Ditto. | |
7611 | * c-lang.c: Dittoxs. | |
7612 | * c-objc-common.c: Ditto. | |
7613 | * c-parser.c: Ditto. | |
7614 | * c-typeck.c: Include hash-set.h, machmode.h, | |
7615 | vec.h, double-int.h, input.h, alias.h, symtab.h, options.h | |
7616 | fold-const.h, wide-int.h, inchash.h, real.h and | |
7617 | fixed-value.h due to flattening of tree.h. | |
7618 | ||
2cc901dc MP |
7619 | 2015-01-07 Marek Polacek <polacek@redhat.com> |
7620 | ||
7621 | PR c/64417 | |
7622 | * c-typeck.c (process_init_element): Disallow initialization of | |
7623 | a flexible array member with a string constant if the structure | |
7624 | is in an array. | |
7625 | ||
5624e564 JJ |
7626 | 2015-01-05 Jakub Jelinek <jakub@redhat.com> |
7627 | ||
e5341100 JJ |
7628 | PR sanitizer/64344 |
7629 | * c-typeck.c (convert_for_assignment, c_finish_return): For | |
7630 | -fsanitize=float-cast-overflow casts from REAL_TYPE to integer/enum | |
7631 | types also set in_late_binary_op around convert call. | |
7632 | * c-convert.c (convert): For -fsanitize=float-cast-overflow REAL_TYPE | |
7633 | to integral type casts, if not in_late_binary_op, pass c_fully_fold | |
7634 | result on expr as last argument to ubsan_instrument_float_cast, | |
7635 | if in_late_binary_op, don't use c_save_expr but save_expr. | |
7636 | ||
5624e564 JJ |
7637 | Update copyright years. |
7638 | ||
5bd012f8 MP |
7639 | 2015-01-05 Marek Polacek <polacek@redhat.com> |
7640 | ||
7641 | PR c/64423 | |
7642 | * c-typeck.c (build_array_ref): Pass loc down to | |
7643 | warn_array_subscript_with_type_char. | |
7644 | ||
3f8257db | 7645 | 2014-12-20 Martin Uecker <uecker@eecs.berkeley.edu> |
768952be MU |
7646 | |
7647 | * c-typeck.c: New behavious for pointers to arrays with qualifiers | |
8e745a17 | 7648 | (common-pointer-type): For pointers to arrays take qualifiers from |
768952be | 7649 | element type. |
8e745a17 | 7650 | (build_conditional_expr): Add warnings for lost qualifiers. |
768952be | 7651 | (comp-target-types): Allow pointers to arrays with different qualifiers. |
8e745a17 | 7652 | (convert-for-assignment): Adapt warnings for discarded qualifiers. Add |
768952be | 7653 | WARNING_FOR_QUALIFIERS macro and rename WARN_FOR_QUALIFIERS |
8e745a17 | 7654 | to PEDWARN_FOR_QUALIFIERS. |
768952be | 7655 | |
8f94a8c4 JJ |
7656 | 2014-12-17 Jakub Jelinek <jakub@redhat.com> |
7657 | ||
7658 | PR sanitizer/64289 | |
7659 | * c-convert.c: Include ubsan.h. | |
7660 | (convert): For real -> integral casts and | |
7661 | -fsanitize=float-cast-overflow don't call convert_to_integer, but | |
7662 | instead instrument the float cast directly. | |
7663 | ||
b731b390 JJ |
7664 | 2014-11-29 Jakub Jelinek <jakub@redhat.com> |
7665 | ||
7666 | * c-typeck.c (convert_lvalue_to_rvalue, build_atomic_assign, | |
7667 | c_finish_stmt_expr): Remove NULL last argument from | |
7668 | create_tmp_var_raw and create_tmp_var calls. | |
7669 | * c-array-notation.c (fix_builtin_array_notation_fn, | |
7670 | build_array_notation_expr, fix_conditional_array_notations_1, | |
7671 | fix_array_notation_expr, fix_array_notation_call_expr): Likewise. | |
7672 | ||
541e35a6 MP |
7673 | 2014-11-28 Marek Polacek <polacek@redhat.com> |
7674 | ||
7675 | PR c/63862 | |
7676 | * c-typeck.c (build_binary_op) <RSHIFT_EXPR, LSHIFT_EXPR>: Don't | |
7677 | convert the right operand to integer type. | |
7678 | ||
b286be94 MP |
7679 | 2014-11-25 Marek Polacek <polacek@redhat.com> |
7680 | ||
7681 | PR c/63877 | |
7682 | * c-decl.c (start_function): Disable -Wmissing-declarations warning | |
7683 | for inline functions. | |
7684 | ||
aa7da51a JJ |
7685 | 2014-11-21 Jakub Jelinek <jakub@redhat.com> |
7686 | ||
7687 | PR target/63764 | |
7688 | * c-typeck.c (build_array_ref): Adjust | |
7689 | convert_vector_to_pointer_for_subscript caller. If it returns true, | |
7690 | call non_lvalue_loc on the result. | |
7691 | ||
d876207f RB |
7692 | 2014-11-11 Richard Biener <rguenther@suse.de> |
7693 | ||
7694 | * c-decl.c (c_init_decl_processing): Do not set pedantic_lvalues | |
7695 | to true. | |
7696 | ||
e5e44252 AK |
7697 | 2014-11-10 Andi Kleen <ak@linux.intel.com> |
7698 | ||
7699 | PR c/60804 | |
7700 | * c-parser.c (c_parser_statement_after_labels): Call | |
7701 | check_no_cilk. | |
7702 | (c_parser_if_statement): Dito. | |
7703 | (c_parser_switch_statement): Dito. | |
7704 | (c_parser_while_statement): Dito. | |
7705 | (c_parser_do_statement): Dito. | |
7706 | (c_parser_for_statement): Dito. | |
7707 | * c-typeck.c (c_finish_loop): Dito. | |
7708 | ||
13c21655 PC |
7709 | 2014-11-10 Paolo Carlini <paolo.carlini@oracle.com> |
7710 | ||
7711 | * c-typeck.c (build_binary_op): Use OPT_Wshift_count_negative and | |
7712 | OPT_Wshift_count_overflow in the warnings. | |
7713 | ||
2d51fcef MP |
7714 | 2014-10-30 Marek Polacek <polacek@redhat.com> |
7715 | ||
7716 | * c-objc-common.c (c_tree_printer) <case 'T'>: For a typedef name, | |
7717 | print the stripped version as well, if they're not the same. | |
7718 | ||
ef4bddc2 RS |
7719 | 2014-10-29 Richard Sandiford <richard.sandiford@arm.com> |
7720 | ||
7721 | * c-decl.c, c-tree.h, c-typeck.c: Remove redundant enum from | |
7722 | machine_mode. | |
7723 | ||
c582198b AM |
7724 | 2014-10-28 Andrew MacLeod <amacleod@redhat.com> |
7725 | ||
7726 | * c-decl.c: Adjust include files. | |
7727 | * c-parser.c: Ditto. | |
7728 | ||
ddc8de03 PM |
7729 | 2014-10-27 Phil Muldoon <pmuldoon@redhat.com> |
7730 | Tom Tromey <tromey@redhat.com> | |
7731 | ||
7732 | * c-tree.h (enum c_oracle_request): New. | |
7733 | (c_binding_oracle_function): New typedef. | |
7734 | (c_binding_oracle, c_pushtag, c_bind): Declare. | |
7735 | * c-decl.c (c_binding_oracle): New global. | |
7736 | (I_SYMBOL_CHECKED): New macro. | |
7737 | (i_symbol_binding): New function. | |
7738 | (I_SYMBOL_BINDING, I_SYMBOL_DECL): Redefine. | |
7739 | (I_TAG_CHECKED): New macro. | |
7740 | (i_tag_binding): New function. | |
7741 | (I_TAG_BINDING, I_TAG_DECL): Redefine. | |
7742 | (I_LABEL_CHECKED): New macro. | |
7743 | (i_label_binding): New function. | |
7744 | (I_LABEL_BINDING, I_LABEL_DECL): Redefine. | |
7745 | (c_print_identifier): Save and restore c_binding_oracle. | |
7746 | (c_pushtag, c_bind): New functions. | |
7747 | ||
60393bbc AM |
7748 | 2014-10-27 Andrew MacLeod <amacleod@redhat.com> |
7749 | ||
7750 | * c-typeck.c: Adjust include files. | |
7751 | ||
d723bb7c MLI |
7752 | 2014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org> |
7753 | ||
7754 | PR c++/53061 | |
7755 | * c-objc-common.c (c_objc_common_init): Do not do diagnostics | |
7756 | initialization here... | |
7757 | (c_initialize_diagnostics): ... but here. Set defaults after | |
7758 | building pretty-printer. | |
7759 | ||
1bc5a451 MP |
7760 | 2014-10-23 Marek Polacek <polacek@redhat.com> |
7761 | ||
7762 | PR c/63626 | |
7763 | * c-decl.c (pop_scope): Don't print warning in external_scope. | |
7764 | ||
4435bb92 MP |
7765 | 2014-10-19 Marek Polacek <polacek@redhat.com> |
7766 | ||
7767 | PR c/63567 | |
7768 | * c-typeck.c (output_init_element): Allow initializing objects with | |
7769 | static storage duration with compound literals even in C99 and add | |
7770 | pedwarn for it. | |
7771 | ||
7278465e MP |
7772 | 2014-10-17 Marek Polacek <polacek@redhat.com> |
7773 | ||
7774 | PR c/63567 | |
7775 | * c-typeck.c (digest_init): Allow initializing objects with static | |
7776 | storage duration with compound literals even in C99 and add pedwarn | |
7777 | for it. | |
7778 | ||
d9b7be2e MP |
7779 | 2014-10-17 Marek Polacek <polacek@redhat.com> |
7780 | ||
7781 | PR c/63543 | |
7782 | * c-tree.h (C_TYPE_ERROR_REPORTED): Define. | |
7783 | * c-typeck.c (build_indirect_ref): Don't print the "dereferencing..." | |
7784 | error multiple times. Print the type. | |
7785 | ||
f406ae1f MP |
7786 | 2014-10-17 Marek Polacek <polacek@redhat.com> |
7787 | ||
7788 | PR c/63549 | |
7789 | * c-typeck.c (build_array_ref): Bail if the index in an incomplete | |
7790 | type. | |
7791 | ||
92574c7c MP |
7792 | 2014-10-17 Marek Polacek <polacek@redhat.com> |
7793 | ||
7794 | * c-decl.c (grokdeclarator): Use OPT_Wimplicit_int unconditionally. | |
7795 | (start_function): Use OPT_Wimplicit_int instead of 0. | |
7796 | (store_parm_decls_oldstyle): Likewise. | |
7797 | ||
1bc4a978 MT |
7798 | 2014-10-17 Alan Modra <amodra@gmail.com> |
7799 | ||
7800 | PR middle-end/61848 | |
7801 | * c-decl.c (merge_decls): Don't merge section name or tls model | |
7802 | to newdecl symtab node, instead merge to olddecl. Override | |
7803 | existing olddecl section name. Set tls_model for all thread-local | |
7804 | vars, not just OMP thread-private ones. Remove incorrect comment. | |
7805 | ||
83685514 AM |
7806 | 2014-10-16 Andrew MacLeod <amacleod@redhat.com> |
7807 | ||
7808 | * c-decl.c: Adjust include files. | |
7809 | ||
78a7c317 DD |
7810 | 2014-10-14 DJ Delorie <dj@redhat.com> |
7811 | ||
7812 | * c-parser.c (c_parse_init): Add RID entries for each __intN. | |
7813 | (c_token_starts_typename): Check all __intN, not just __int128. | |
7814 | (c_token_starts_declspecs): Likewise. | |
7815 | (c_parser_declspecs): Likewise. | |
7816 | (c_parser_attribute_any_word): Likewise. | |
7817 | (c_parser_objc_selector): Likewise. | |
7818 | * c-tree.h (c_typespec_keyword): cts_int128 -> cts_int_n. | |
7819 | (struct c_declspecs): Add int_n_idx field to record *which* __intN | |
7820 | is specified. | |
7821 | * c-decl.c (declspecs_add_type): Check for all __intN, not just | |
7822 | __int128. | |
7823 | (finish_declspecs): Likewise. | |
7824 | ||
74d98c1e AB |
7825 | 2014-10-13 Anthony Brandon <anthony.brandon@gmail.com> |
7826 | ||
8e745a17 | 7827 | * c-parser.c (c_parser_all_labels): New function to replace |
74d98c1e | 7828 | the duplicate code. |
8e745a17 | 7829 | (c_parser_statement): Call the new function. |
74d98c1e | 7830 | |
84937de2 MP |
7831 | 2014-10-09 Marek Polacek <polacek@redhat.com> |
7832 | ||
7833 | PR c/63480 | |
7834 | * c-typeck.c (pop_init_level): Don't warn about initializing | |
7835 | with { }. | |
7836 | ||
0382aaa0 MP |
7837 | 2014-10-07 Marek Polacek <polacek@redhat.com> |
7838 | ||
7839 | PR c/59717 | |
7840 | * c-decl.c (header_for_builtin_fn): New function. | |
7841 | (implicitly_declare): Suggest which header to include. | |
7842 | ||
7a0ca710 MP |
7843 | 2014-10-07 Marek Polacek <polacek@redhat.com> |
7844 | ||
7845 | * c-convert.c (convert): Use error_operand_p. | |
7846 | * c-typeck.c (require_complete_type): Likewise. | |
7847 | (really_atomic_lvalue): Likewise. | |
7848 | (digest_init): Likewise. | |
7849 | (handle_omp_array_sections_1): Likewise. | |
7850 | ||
6bc8a126 MP |
7851 | 2014-10-03 Marek Polacek <polacek@redhat.com> |
7852 | ||
7853 | PR c/63453 | |
7854 | * c-decl.c (pop_scope): Don't warn about "inline function declared | |
7855 | but never defined" for functions marked with gnu_inline attribute. | |
7856 | ||
d90c0a59 JJ |
7857 | 2014-09-25 Jakub Jelinek <jakub@redhat.com> |
7858 | ||
7859 | PR c++/63249 | |
7860 | * c-parser.c (c_parser_omp_variable_list): Call mark_exp_read | |
7861 | on low_bound and length. | |
7862 | ||
083e891e MP |
7863 | 2014-09-24 Marek Polacek <polacek@redhat.com> |
7864 | ||
7865 | PR c/61405 | |
7866 | PR c/53874 | |
7867 | * c-parser.c: Don't define CPP_KEYWORD. | |
7868 | (c_parser_switch_statement): Pass original type to c_finish_case. | |
7869 | * c-tree.h (c_finish_case): Update declaration. | |
7870 | * c-typeck.c (c_finish_case): Add TYPE parameter. Pass it | |
7871 | conditionally to c_do_switch_warnings. | |
7872 | ||
8d95fe25 MP |
7873 | 2014-09-03 Marek Polacek <polacek@redhat.com> |
7874 | ||
7875 | PR c/62024 | |
7876 | * c-parser.c (c_parser_static_assert_declaration_no_semi): Strip no-op | |
7877 | conversions. | |
7878 | ||
9a771876 JJ |
7879 | 2014-09-02 Jakub Jelinek <jakub@redhat.com> |
7880 | Balaji V. Iyer <balaji.v.iyer@intel.com> | |
7881 | Igor Zamyatin <igor.zamyatin@intel.com> | |
7882 | ||
7883 | * c-parser.c (c_parser_cilk_for): New function. | |
7884 | (c_parser_cilk_grainsize): Likewise. | |
7885 | (c_get_temp_regvar): Likewise. | |
7886 | (c_parser_statement_after_labels): Added RID_CILK_FOR case. | |
7887 | (c_parser_pragma): Added PRAGMA_CILK_GRAINSIZE case. | |
7888 | (c_parser_omp_for_loop): Added CILK_FOR and CILK_SIMD checks. | |
7889 | * c-typeck.c (c_finish_omp_clauses): Added OMP_CLAUSE__CILK_FOR_COUNT_ | |
7890 | case. | |
7891 | ||
b7679d96 CG |
7892 | 2014-08-27 Chen Gang <gang.chen.5i5j@gmail.com> |
7893 | ||
7894 | * c-aux-info.c (gen_type): Resize 'buff' from 10 to 23 bytes, | |
7895 | with using HOST_WIDE_INT without truncation to 'int' | |
7896 | ||
59ea0364 MP |
7897 | 2014-08-22 Marek Polacek <polacek@redhat.com> |
7898 | ||
7899 | PR c++/62199 | |
7900 | * c-typeck.c (parser_build_binary_op): Adjust call to | |
7901 | warn_logical_not_parentheses. | |
7902 | ||
671a475e IZ |
7903 | 2014-08-22 Igor Zamyatin <igor.zamyatin@intel.com> |
7904 | ||
7905 | PR other/62008 | |
7906 | * c-parser.c (c_parser_array_notation): Check for correct | |
7907 | type of an array added. | |
7908 | ||
04159acf MP |
7909 | 2014-08-19 Marek Polacek <polacek@redhat.com> |
7910 | ||
7911 | PR c++/62153 | |
7912 | * c-typeck.c (build_binary_op): If either operand of a comparison | |
7913 | is a boolean expression, call maybe_warn_bool_compare. | |
7914 | ||
c77935ee PP |
7915 | 2014-08-19 Patrick Palka <ppalka@gcc.gnu.org> |
7916 | ||
7917 | PR c/45584 | |
7918 | * c-typeck.c (build_c_cast): Do a conversion even when the | |
7919 | TYPE_MAIN_VARIANTs are the same. | |
7920 | ||
35aff4fb MP |
7921 | 2014-08-19 Marek Polacek <polacek@redhat.com> |
7922 | ||
7923 | * c-decl.c (diagnose_mismatched_decls): Unconditionally call | |
7924 | pedwarn_c99 instead of pedwarn. | |
7925 | (grokfield): Likewise. | |
7926 | (warn_defaults_to): New function. | |
7927 | (grokdeclarator): Call warn_defaults_to instead of pedwarn_c99. | |
7928 | Unconditionally call pedwarn_c99 instead of pedwarn. | |
7929 | (start_function): Call warn_defaults_to instead of pedwarn_c99. | |
7930 | (declspecs_add_scspec): Call pedwarn_c99 instead of pedwarn, don't | |
7931 | check flag_isoc11 before. | |
7932 | * c-errors.c (pedwarn_c99): Change the return type to bool. | |
7933 | Handle -Wc99-c11-compat. | |
7934 | * c-parser.c (disable_extension_diagnostics): Handle | |
7935 | warn_c99_c11_compat. | |
7936 | (restore_extension_diagnostics): Likewise. | |
7937 | (c_parser_static_assert_declaration_no_semi): Call pedwarn_c99 | |
7938 | instead of pedwarn, don't check flag_isoc11 before. | |
7939 | (c_parser_declspecs): Likewise. | |
7940 | (c_parser_alignas_specifier): Likewise. | |
7941 | (c_parser_alignof_expression): Likewise. | |
7942 | (c_parser_generic_selection): Likewise. | |
7943 | * c-tree.h (pedwarn_c99): Update declaration. | |
7944 | * c-typeck.c (c_finish_return): Call pedwarn or warning_at instead | |
7945 | of pedwarn_c99. | |
7946 | ||
177cce46 MP |
7947 | 2014-08-19 Marek Polacek <polacek@redhat.com> |
7948 | ||
7949 | * c-decl.c (warn_variable_length_array): Pass OPT_Wvla unconditionally | |
7950 | to pedwarn_c90. | |
7951 | * c-errors.c: Include "opts.h". | |
7952 | (pedwarn_c90): Rewrite to handle -Wno-c90-c99-compat better. | |
7953 | * c-parser.c (disable_extension_diagnostics): Handle negative value | |
7954 | of warn_c90_c99_compat, too. | |
7955 | (restore_extension_diagnostics): Likewise. | |
7956 | (c_parser_compound_statement_nostart): Pass | |
7957 | OPT_Wdeclaration_after_statement unconditionally to pedwarn_c90. | |
7958 | ||
6dc99c33 MP |
7959 | 2014-08-12 Marek Polacek <polacek@redhat.com> |
7960 | ||
7961 | * c-parser.c (c_parser_postfix_expression) <case RID_FUNCTION_NAME>: | |
7962 | Add pedwarn. | |
7963 | (c_parser_postfix_expression) <case RID_PRETTY_FUNCTION_NAME>: | |
7964 | Likewise. | |
7965 | (c_parser_postfix_expression) <case RID_C99_FUNCTION_NAME>: Likewise. | |
7966 | ||
3f8257db | 7967 | 2014-08-10 Marek Polacek <polacek@redhat.com> |
f3bede71 MP |
7968 | |
7969 | PR c/51849 | |
7970 | * c-decl.c (build_array_declarator): Remove check for !flag_isoc99. | |
7971 | Call pedwarn_c90 instead of pedwarn. | |
7972 | (check_bitfield_type_and_width): Likewise. | |
7973 | (declspecs_add_qual): Likewise. | |
7974 | (declspecs_add_type): Likewise. | |
7975 | (warn_variable_length_array): Unify function for -pedantic and -Wvla. | |
7976 | Adjust to only call pedwarn_c90. | |
7977 | (grokdeclarator): Remove pedantic && !flag_isoc99 check. Call | |
7978 | pedwarn_c90 instead of pedwarn. | |
7979 | * c-errors.c (pedwarn_c90): Handle -Wc90-c99-compat. | |
7980 | * c-parser.c (disable_extension_diagnostics): Handle | |
7981 | warn_c90_c99_compat. | |
7982 | (restore_extension_diagnostics): Likewise. | |
7983 | (c_parser_enum_specifier): Remove check for !flag_isoc99. Call | |
7984 | pedwarn_c90 instead of pedwarn. | |
7985 | (c_parser_initelt): Likewise. | |
7986 | (c_parser_postfix_expression): Likewise. | |
7987 | (c_parser_postfix_expression_after_paren_type): Likewise. | |
7988 | (c_parser_compound_statement_nostart): Remove check for !flag_isoc99. | |
7989 | * c-tree.h: Fix formatting. | |
7990 | * c-typeck.c (build_array_ref): Remove check for !flag_isoc99. Call | |
7991 | pedwarn_c90 instead of pedwarn. | |
7992 | ||
9f25a338 TS |
7993 | 2014-08-07 Trevor Saunders <tsaunders@mozilla.com> |
7994 | ||
7995 | * c-typeck.c: Remove include of pointer-set.h. | |
7996 | ||
044331a8 MP |
7997 | 2014-08-07 Marek Polacek <polacek@redhat.com> |
7998 | ||
7999 | * c-typeck.c (pointer_diff): Remove P - (P + CST) optimization. | |
8000 | ||
b787e7a2 TS |
8001 | 2014-08-02 Trevor Saunders <tsaunders@mozilla.com> |
8002 | ||
8003 | * c-typeck.c: Use hash_map instead of pointer_map. | |
8004 | ||
6e2830c3 TS |
8005 | 2014-08-02 Trevor Saunders <tsaunders@mozilla.com> |
8006 | ||
8007 | * c-decl.c: Use hash_set instead of pointer_set. | |
8008 | ||
a7ee52fb IZ |
8009 | 2014-08-01 Igor Zamyatin <igor.zamyatin@intel.com> |
8010 | ||
8011 | PR middle-end/61455 | |
8012 | * c-array-notation.c (expand_array_notations): Handling | |
8013 | of DECL_EXPR added. | |
8014 | ||
b4dfdc11 MG |
8015 | 2014-07-31 Marc Glisse <marc.glisse@inria.fr> |
8016 | ||
8017 | PR c++/60517 | |
8018 | * c-typeck.c (c_finish_return): Return 0 instead of the address of | |
8019 | a local variable. | |
8020 | ||
976d5a22 TT |
8021 | 2014-07-30 Tom Tromey <tromey@redhat.com> |
8022 | ||
8023 | * c-typeck.c (struct constructor_stack) <designator_depth>: New | |
8024 | field. | |
8025 | (really_start_incremental_init, push_init_level): Initialize | |
8026 | designator_depth. | |
8027 | (pop_init_level): Set global designator_depth. | |
8028 | (process_init_element): Check for designated_init attribute. | |
8029 | ||
30281de2 MP |
8030 | 2014-07-20 Marek Polacek <polacek@redhat.com> |
8031 | ||
8032 | PR c/61852 | |
8033 | * c-decl.c (implicit_decl_warning): Add location_t parameter. Use it. | |
8034 | (implicitly_declare): Pass location to implicit_decl_warning. | |
8035 | ||
b108f48f JJ |
8036 | 2014-07-14 Jakub Jelinek <jakub@redhat.com> |
8037 | ||
8038 | PR middle-end/61294 | |
8039 | * c-parser.c (c_parser_expr_list): Add new argument literal_zero_mask. | |
8040 | If non-NULL, call c_parser_check_literal_zero. | |
8041 | (c_parser_check_literal_zero): New function. | |
8042 | (c_parser_postfix_expression_after_primary): Adjust | |
8043 | c_parser_expr_list caller, handle -Wmemset-transposed-args. | |
8044 | ||
773ec47f MP |
8045 | 2014-07-06 Marek Polacek <polacek@redhat.com> |
8046 | ||
8047 | PR c/6940 | |
8048 | * c-decl.c (grokdeclarator): Set C_ARRAY_PARAMETER. | |
8049 | * c-tree.h (C_ARRAY_PARAMETER): Define. | |
8050 | * c-typeck.c (c_expr_sizeof_expr): Warn when using sizeof on an array | |
8051 | function parameter. | |
8052 | ||
22e1cf1c | 8053 | 2014-07-02 Jan Hubicka <hubicka@ucw.cz> |
3f8257db | 8054 | Chen Gang <gang.chen.5i5j@gmail.com> |
22e1cf1c JH |
8055 | |
8056 | * c-decl.c (duplicate_decls): CLear DECL_STRUCT_FUNCTION before | |
8057 | releasing symbol. | |
8058 | ||
52ec0ea3 MP |
8059 | 2014-07-01 Marek Polacek <polacek@redhat.com> |
8060 | ||
8061 | * c-typeck.c (convert_for_assignment): Pass OPT_Wint_conversion | |
8062 | instead of 0 to WARN_FOR_ASSIGNMENT. | |
8063 | ||
d5c3d343 MP |
8064 | 2014-07-01 Marek Polacek <polacek@redhat.com> |
8065 | ||
8066 | PR c/58286 | |
8067 | * c-typeck.c (convert_for_assignment): Pass | |
8068 | OPT_Wincompatible_pointer_types instead of 0 to WARN_FOR_ASSIGNMENT. | |
8069 | ||
6a7253a4 MP |
8070 | 2014-06-30 Marek Polacek <polacek@redhat.com> |
8071 | ||
8072 | * c-decl.c (grokdeclarator): Don't instrument VLAs if the function | |
8073 | has no_sanitize_undefined attribute. | |
8074 | ||
5e88a8f4 IZ |
8075 | 2014-06-30 Igor Zamyatin <igor.zamyatin@intel.com> |
8076 | ||
8077 | PR middle-end/57541 | |
8078 | * c-array-notation.c (fix_builtin_array_notation_fn): | |
8079 | Check for 0 arguments in builtin call. Check that bultin argument is | |
8080 | correct. | |
8081 | * c-parser.c (c_parser_array_notation): Check for incorrect initial | |
8082 | index. | |
8083 | ||
9698b078 SH |
8084 | 2014-06-27 Sebastian Huber <sebastian.huber@embedded-brains.de> |
8085 | ||
8086 | * c-parser.c (c_parser_declaration_or_fndef): Discard all type | |
8087 | qualifiers in __auto_type for atomic types. | |
8088 | (c_parser_typeof_specifier): Discard all type qualifiers in | |
8089 | __typeof__ for atomic types. | |
8090 | ||
6e07c515 MP |
8091 | 2014-06-25 Marek Polacek <polacek@redhat.com> |
8092 | ||
8093 | PR c/61162 | |
8094 | * c-parser.c (c_parser_statement_after_labels): Pass the location of | |
8095 | the return expression to c_finish_return. | |
8096 | ||
da6f124d JJ |
8097 | 2014-06-25 Jakub Jelinek <jakub@redhat.com> |
8098 | ||
8099 | * c-typeck.c (c_finish_omp_clauses): Make sure | |
8100 | OMP_CLAUSE_LINEAR_STEP has correct type. | |
8101 | ||
c203e8a7 TS |
8102 | 2014-06-24 Trevor Saunders <tsaunders@mozilla.com> |
8103 | ||
8104 | * c-decl.c: Adjust. | |
8105 | ||
56ad0e38 JJ |
8106 | 2014-06-24 Jakub Jelinek <jakub@redhat.com> |
8107 | ||
8108 | * c-parser.c (c_parser_omp_for_loop): For | |
8109 | #pragma omp parallel for simd move lastprivate clause from parallel | |
8110 | to for rather than simd. | |
8111 | ||
47c2554f MP |
8112 | 2014-06-23 Marek Polacek <polacek@redhat.com> |
8113 | ||
8114 | * c-typeck.c (parser_build_binary_op): Don't call | |
8115 | warn_logical_not_parentheses if the RHS is TRUTH_NOT_EXPR. | |
8116 | ||
56363ffd JH |
8117 | 2014-06-15 Jan Hubicka <hubicka@ucw.cz> |
8118 | ||
8119 | * c-parser.c (c_parser_omp_threadprivate): Likewise. | |
8120 | * c-decl.c (merge_decls): Likewise. | |
8121 | ||
d7ff7ae5 MP |
8122 | 2014-06-09 Marek Polacek <polacek@redhat.com> |
8123 | ||
8124 | PR c/36446 | |
8125 | * c-typeck.c (error_init): Call inform instead of error_at. | |
8126 | (pedwarn_init): Call inform instead of pedwarn. | |
8127 | (warning_init): Call inform instead of warning_at. | |
8128 | ||
24d047a3 JH |
8129 | 2014-06-07 Jan Hubicka <hubicka@ucw.cz> |
8130 | ||
8131 | * c-decl.c (merge_decls): Use set_decl_section_name. | |
8132 | (duplicate_decls): Remove node if it exists. | |
8133 | ||
9bac5cbb G |
8134 | 2014-06-05 S. Gilles <sgilles@terpmail.umd.edu> |
8135 | ||
8136 | PR c/53119 | |
8137 | * c-typeck.c (push_init_level, process_init_element, | |
8138 | pop_init_level): Correct check for zero initialization, move | |
8139 | missing brace warning to respect zero initialization. | |
8140 | ||
8ffcdea8 MP |
8141 | 2014-06-05 Marek Polacek <polacek@redhat.com> |
8142 | ||
8143 | PR c/56724 | |
8144 | * c-typeck.c (convert_for_assignment): Use expr_loc for ic_argpass. | |
8145 | ||
742938c9 MP |
8146 | 2014-06-05 Marek Polacek <polacek@redhat.com> |
8147 | ||
8148 | PR c/49706 | |
8149 | * c-typeck.c (parser_build_binary_op): Warn when logical not is used | |
ab20d992 | 8150 | on the left hand side operand of a comparison. |
742938c9 | 8151 | |
6447c55d MP |
8152 | 2014-06-05 Marek Polacek <polacek@redhat.com> |
8153 | ||
8154 | PR c/48062 | |
8155 | * c-decl.c (warn_if_shadowing): Call inform instead of warning_at. | |
8156 | Print note only if the warning was printed. | |
8157 | ||
9dc7743c IZ |
8158 | 2014-06-04 Igor Zamyatin <igor.zamyatin@intel.com> |
8159 | ||
8160 | PR c/58942 | |
8161 | * c-array-notation.c (fix_builtin_array_notation_fn): Handle the case | |
8162 | with a pointer. | |
8163 | ||
fedfecef MP |
8164 | 2014-06-03 Marek Polacek <polacek@redhat.com> |
8165 | ||
8166 | PR c/60439 | |
8167 | * c-parser.c (c_parser_switch_statement): Pass explicit_cast_p to | |
8168 | c_start_case. | |
8169 | * c-tree.h (c_start_case): Update. | |
8170 | * c-typeck.c (c_start_case): Add new boolean parameter. Warn if | |
8171 | switch condition has boolean value. | |
8172 | ||
9b2b7279 AM |
8173 | 2014-06-02 Andrew MacLeod <amacleod@redhat.com> |
8174 | ||
8175 | * c-decl.c: Include builtins.h. | |
8176 | * c-parser.c: Likewise. | |
8177 | ||
5c1bc275 MP |
8178 | 2014-05-27 Marek Polacek <polacek@redhat.com> |
8179 | ||
8180 | PR c/56724 | |
8181 | * c-typeck.c (convert_arguments): Get location of a parameter. Change | |
8182 | error and warning calls to error_at and warning_at. Pass location of | |
8183 | a parameter to it. Call warning_at with OPT_Wtraditional_conversion. | |
8184 | (convert_for_assignment): Add parameter to WARN_FOR_ASSIGNMENT and | |
8185 | WARN_FOR_QUALIFIERS. Pass expr_loc to those. | |
8186 | ||
97563bc8 IZ |
8187 | 2014-05-26 Igor Zamyatin <igor.zamyatin@intel.com> |
8188 | ||
8189 | PR c/61191 | |
8190 | * c-array-notation.c (fix_builtin_array_notation_fn): Check invalid | |
8191 | function parameters. | |
8192 | ||
aede2c10 JH |
8193 | 2014-05-23 Jan Hubicka <hubicka@ucw.cz> |
8194 | ||
8195 | * c-decl.c (merge_decls): Preserve symtab node pointers. | |
8196 | (duplicate_decls): Free new decl. | |
8197 | ||
edbba2ce TS |
8198 | 2014-05-23 Thomas Schwinge <thomas@codesourcery.com> |
8199 | ||
f3316c6d TS |
8200 | * c-typeck.c (c_finish_omp_clauses): Remove duplicated variable |
8201 | initialization. | |
8202 | ||
edbba2ce TS |
8203 | * c-parser.c (c_parser_omp_target): Return bool values. |
8204 | ||
68c81f24 TS |
8205 | 2014-05-22 Thomas Schwinge <thomas@codesourcery.com> |
8206 | ||
8207 | * c-parser.c (c_parser_omp_clause_thread_limit): Rename | |
8208 | num_teams_loc variable to num_thread_limit_loc. | |
8209 | ||
632f2871 RS |
8210 | 2014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com> |
8211 | ||
8212 | * c-array-notation.c (expand_array_notations): Use void_node | |
8213 | instead of void_zero_node. | |
8214 | ||
766090c2 TS |
8215 | 2014-05-17 Trevor Saunders <tsaunders@mozilla.com> |
8216 | ||
8217 | * c-decl.c (finish_struct): Adjust. | |
8218 | (finish_enum): Likewise. | |
8219 | (bind): Adjust. | |
8220 | (record_inline_static): Likewise. | |
8221 | (push_scope): Likewise. | |
8222 | (make_label): Likewise. | |
8223 | (lookup_label_for_goto): Likewise. | |
8224 | (finish_struct): Likewise. | |
8225 | (finish_enum): Likewise. | |
8226 | (store_parm_decls): Likewise. | |
8227 | (c_push_function_context): Likewise. | |
8228 | * c-lang.h: Remove usage of variable_size gty attribute. | |
8229 | * c-parser.c (c_parse_init): Adjust. | |
8230 | (c_parse_file): Likewise. | |
8231 | ||
2b107f6b MP |
8232 | 2014-05-13 Marek Polacek <polacek@redhat.com> |
8233 | ||
8234 | PR c/61162 | |
8235 | * c-typeck.c (convert_for_assignment): Pass location to | |
8236 | WARN_FOR_ASSIGNMENT instead of input_location. | |
8237 | ||
d033409e MP |
8238 | 2014-05-10 Marek Polacek <polacek@redhat.com> |
8239 | ||
8240 | * c-parser.c (c_parser_declaration_or_fndef): Pass init_loc to | |
8241 | maybe_warn_string_init. | |
8242 | (c_parser_postfix_expression_after_paren_type): Pass type_loc to | |
8243 | maybe_warn_string_init. | |
8244 | * c-tree.h (maybe_warn_string_init): Update declaration. | |
8245 | * c-typeck.c (maybe_warn_string_init): Add location parameter. | |
8246 | Call pedwarn_init with loc instead of with input_location. | |
8247 | (digest_init): Pass init_loc to maybe_warn_string_init. | |
8248 | (pop_init_level): Call pedwarn_init with loc instead of with | |
8249 | input_location. | |
8250 | (set_init_index): Likewise. | |
8251 | (process_init_element): Likewise. | |
8252 | ||
ea58ef42 MP |
8253 | 2014-05-09 Marek Polacek <polacek@redhat.com> |
8254 | ||
8255 | PR c/61096 | |
8256 | * c-parser.c (c_parser_braced_init): Pass brace_loc to push_init_level. | |
8257 | (c_parser_initelt): Pass location to set_init_label. Pass array index | |
8258 | location to set_init_index. | |
8259 | * c-tree.h (push_init_level): Update declaration. | |
8260 | (pop_init_level): Likewise. | |
8261 | (set_init_index): Likewise. | |
8262 | (set_init_label): Likewise. | |
8263 | * c-typeck.c (error_init): Add location parameter. Call error_at | |
8264 | instead of error. | |
8265 | (digest_init): Pass init_loc to error_init. | |
8266 | (really_start_incremental_init): | |
8267 | (push_init_level): Add location parameter. Pass loc to pop_init_level | |
8268 | and error_init. | |
8269 | (pop_init_level): Likewise. | |
8270 | (set_designator): Add location parameter. Pass loc to pop_init_level, | |
8271 | push_init_level, and error_init. | |
8272 | (set_init_index): Add location parameter. Pass loc to error_init and | |
8273 | set_designator. | |
8274 | (set_init_label): Likewise. | |
8275 | (output_init_element): Pass loc to error_init. | |
8276 | (process_init_element): Pass loc to error_init, pop_init_level, | |
8277 | pedwarn_init, and push_init_level. | |
8278 | ||
661a0813 MP |
8279 | 2014-05-09 Marek Polacek <polacek@redhat.com> |
8280 | ||
8281 | PR c/50459 | |
8282 | * c-parser.c (c_parser_attributes): Parse the arguments as an | |
8283 | expression-list if the attribute takes identifier. | |
8284 | ||
2793eeab MP |
8285 | 2014-05-08 Marek Polacek <polacek@redhat.com> |
8286 | ||
8287 | PR c/61053 | |
8288 | * c-decl.c (grokdeclarator): Use min_align_of_type instead of | |
8289 | TYPE_ALIGN_UNIT. | |
8290 | ||
f827930a MP |
8291 | 2014-05-08 Marek Polacek <polacek@redhat.com> |
8292 | ||
8293 | PR c/61077 | |
8294 | * c-decl.c (start_function): Warn for _Atomic-qualified return type | |
8295 | of main. | |
8296 | ||
1d60af08 KZ |
8297 | 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com> |
8298 | Mike Stump <mikestump@comcast.net> | |
8299 | Richard Sandiford <rdsandiford@googlemail.com> | |
8300 | ||
8301 | * c-decl.c (check_bitfield_type_and_width): Use TYPE_SIGN. | |
8302 | (finish_enum): Use wide-int interfaces. | |
8303 | * c-parser.c (c_parser_cilk_clause_vectorlength): Likewise. | |
8304 | * c-typeck.c (build_c_cast): Likewise. | |
8305 | (set_nonincremental_init_from_string): Likewise. | |
8306 | (c_tree_equal): Likewise. | |
8307 | ||
a0e24419 MP |
8308 | 2014-05-02 Marek Polacek <polacek@redhat.com> |
8309 | ||
8310 | PR c/25801 | |
8311 | * c-typeck.c (c_size_in_bytes): Update comment. Don't call error. | |
8312 | Return size_one_node when the type is not complete. | |
8313 | (pointer_diff): Remove comment. | |
8314 | (build_unary_op): Improve error messages. | |
8315 | ||
19fc9faa MP |
8316 | 2014-05-02 Marek Polacek <polacek@redhat.com> |
8317 | ||
8318 | * c-typeck.c (c_finish_return): Separate warning_at calls. | |
8319 | ||
63bc4e87 MP |
8320 | 2014-05-02 Marek Polacek <polacek@redhat.com> |
8321 | ||
8322 | * c-tree.h (error_init): Remove declaration. | |
8323 | (pedwarn_init): Likewise. | |
8324 | * c-typeck.c (error_init): Make static and move above. | |
8325 | (pedwarn_init): Likewise. | |
8326 | (warning_init): Move above. | |
8327 | (maybe_warn_string_init): Likewise. | |
8328 | ||
4bd2511b JL |
8329 | 2014-05-01 Jeff Law <law@redhat.com> |
8330 | ||
8331 | Revert: | |
8332 | ||
8333 | 2014-04-24 Prathamesh Kulkarni <bilbotheelffriend@gmail.com> | |
8334 | * c-parser.c (c_parser_sizeof_expression): Reorganize slightly to | |
8335 | avoid goto. | |
8336 | ||
6a358dcb MP |
8337 | 2014-05-02 Marek Polacek <polacek@redhat.com> |
8338 | ||
8339 | PR c/60784 | |
8340 | * c-typeck.c (push_init_level): Set constructor_designated to | |
8341 | p->designated for structures. | |
8342 | ||
ae5ebda4 MP |
8343 | 2014-05-01 Marek Polacek <polacek@redhat.com> |
8344 | ||
8345 | PR c/60915 | |
8346 | * c-parser.c (c_parser_declaration_or_fndef): Give better error if | |
8347 | function-definition has an attribute after the declarator. | |
8348 | ||
96b40f8d MP |
8349 | 2014-05-01 Marek Polacek <polacek@redhat.com> |
8350 | ||
8351 | PR c/60257 | |
8352 | * c-typeck.c (warning_init): Add location_t parameter. Call | |
8353 | warning_at instead of warning. | |
8354 | (push_init_level): Pass input_location to warning_init. | |
8355 | (add_pending_init): Add location_t parameter. Pass loc to | |
8356 | warning_init. | |
8357 | (set_nonincremental_init): Pass input_location to add_pending_init. | |
8358 | (set_nonincremental_init_from_string): Likewise. | |
8359 | (output_init_element): Pass loc to warning_init and to | |
8360 | add_pending_init. | |
8361 | ||
32e00768 MP |
8362 | 2014-05-01 Marek Polacek <polacek@redhat.com> |
8363 | ||
8364 | PR c/43395 | |
8365 | * c-typeck.c (c_finish_return): Distinguish between label and variable | |
8366 | when warning about returning local address. | |
8367 | ||
c9379ce2 MP |
8368 | 2014-05-01 Marek Polacek <polacek@redhat.com> |
8369 | ||
8370 | PR c/29467 | |
8371 | * c-decl.c (declspecs_add_type): Pedwarn if boolean types are used | |
8372 | in C89 mode. | |
8373 | ||
d00887e8 MP |
8374 | 2014-05-01 Marek Polacek <polacek@redhat.com> |
8375 | ||
8376 | PR c/43245 | |
8377 | * c-typeck.c (convert_for_assignment): Pass OPT_Wdiscarded_qualifiers | |
8378 | instead of 0 to WARN_FOR_QUALIFIERS. | |
8379 | ||
5436fa2e MP |
8380 | 2014-05-01 Marek Polacek <polacek@redhat.com> |
8381 | ||
8382 | PR c/56989 | |
8383 | * c-typeck.c (default_conversion): Use better location for | |
8384 | error call. | |
8385 | ||
f8ed5150 MP |
8386 | 2014-04-30 Marek Polacek <polacek@redhat.com> |
8387 | ||
8388 | * c-typeck.c (build_binary_op): Call ubsan_instrument_division | |
8389 | also when SANITIZE_FLOAT_DIVIDE is on. | |
8390 | ||
8337d1db MP |
8391 | 2014-04-30 Marek Polacek <polacek@redhat.com> |
8392 | ||
8393 | PR c/60139 | |
8394 | * c-typeck.c (output_init_element): Pass OPT_Wpedantic to pedwarn | |
8395 | and pedwarn_init. Use loc insted of input_location. | |
8396 | ||
c4bdc42f MP |
8397 | 2014-04-30 Marek Polacek <polacek@redhat.com> |
8398 | ||
8399 | PR c/60351 | |
8400 | * c-typeck.c (build_binary_op): Use location when warning about | |
8401 | shift count. | |
8402 | ||
45484dcf MP |
8403 | 2014-04-25 Marek Polacek <polacek@redhat.com> |
8404 | ||
8405 | PR c/18079 | |
8406 | * c-decl.c (diagnose_mismatched_decls): Warn for mismatched | |
8407 | always_inline/noinline and hot/cold attributes. | |
8408 | ||
34cf811f MP |
8409 | 2014-04-25 Marek Polacek <polacek@redhat.com> |
8410 | ||
8411 | PR c/60114 | |
8412 | * c-parser.c (c_parser_initelt): Pass input_location to | |
8413 | process_init_element. | |
8414 | (c_parser_initval): Pass loc to process_init_element. | |
8415 | * c-tree.h (process_init_element): Adjust declaration. | |
8416 | * c-typeck.c (push_init_level): Pass input_location to | |
8417 | process_init_element. | |
8418 | (pop_init_level): Likewise. | |
8419 | (set_designator): Likewise. | |
8420 | (output_init_element): Add location_t parameter. Pass loc to | |
8421 | digest_init. | |
8422 | (output_pending_init_elements): Pass input_location to | |
8423 | output_init_element. | |
8424 | (process_init_element): Add location_t parameter. Pass loc to | |
8425 | output_init_element. | |
8426 | ||
42056eac JJ |
8427 | 2014-04-24 Jakub Jelinek <jakub@redhat.com> |
8428 | ||
8429 | * c-parser.c (c_parser_omp_atomic): Allow seq_cst before | |
8430 | atomic-clause, allow comma in between atomic-clause and | |
8431 | seq_cst. | |
8432 | ||
e162a134 JJ |
8433 | 2014-04-22 Jakub Jelinek <jakub@redhat.com> |
8434 | ||
8435 | PR c/59073 | |
8436 | * c-parser.c (c_parser_omp_parallel): If c_parser_omp_for | |
8437 | fails, don't set OM_PARALLEL_COMBINED and return NULL. | |
8438 | ||
2f6babac IZ |
8439 | 2014-04-12 Igor Zamyatin <igor.zamyatin@intel.com> |
8440 | ||
8441 | PR middle-end/60469 | |
8442 | * c-array-notation.c (fix_builtin_array_notation_fn): Use | |
8443 | create_tmp_var instead build_decl for creating temps. | |
8444 | (build_array_notation_expr): Likewise. | |
8445 | (fix_conditional_array_notations_1): Likewise. | |
8446 | (fix_array_notation_expr): Likewise. | |
8447 | (fix_array_notation_call_expr): Likewise. | |
8448 | ||
8edbfaa6 JJ |
8449 | 2014-03-28 Jakub Jelinek <jakub@redhat.com> |
8450 | ||
8451 | PR c++/60689 | |
8452 | * c-tree.h (c_build_function_call_vec): New prototype. | |
8453 | * c-typeck.c (build_function_call_vec): Don't call | |
8454 | resolve_overloaded_builtin here. | |
8455 | (c_build_function_call_vec): New wrapper function around | |
8456 | build_function_call_vec. Call resolve_overloaded_builtin here. | |
8457 | (convert_lvalue_to_rvalue, build_function_call, build_atomic_assign): | |
8458 | Call c_build_function_call_vec instead of build_function_call_vec. | |
8459 | * c-parser.c (c_parser_postfix_expression_after_primary): Likewise. | |
8460 | * c-decl.c (finish_decl): Likewise. | |
8461 | ||
7485aeea MLI |
8462 | 2014-03-18 Manuel López-Ibáñez <manu@gcc.gnu.org> |
8463 | ||
8464 | PR c/55383 | |
8465 | * c-typeck.c: Use correct format string in cast-qual warning | |
8466 | ||
b17a8b07 TS |
8467 | 2014-03-07 Thomas Schwinge <thomas@codesourcery.com> |
8468 | ||
8469 | * c-decl.c (c_decl_attributes): Use | |
8470 | lang_hooks.types.omp_mappable_type. | |
8471 | * c-typeck.c (c_finish_omp_clauses): Likewise. | |
8472 | ||
3af9c5e9 MP |
8473 | 2014-03-06 Marek Polacek <polacek@redhat.com> |
8474 | ||
8475 | PR c/60197 | |
8476 | * c-typeck.c (c_finish_return): Call contains_cilk_spawn_stmt instead | |
8477 | of checking tree code. | |
8478 | ||
1c9f5f33 PK |
8479 | 2014-02-19 Prathamesh Kulkarni <bilbotheelffriend@gmail.com> |
8480 | ||
8481 | * c-parser.c (c_parser_declspecs): Replace call to error by error_at. | |
8482 | (c_parser_parameter_declaration): Likewise. | |
8483 | ||
cc28fc7f MP |
8484 | 2014-02-19 Marek Polacek <polacek@redhat.com> |
8485 | ||
8486 | PR c/60195 | |
8487 | * c-typeck.c (convert_lvalue_to_rvalue): Set TREE_NO_WARNING on tmp. | |
8488 | Call mark_exp_read on exp.value. | |
8489 | (build_atomic_assign): Set TREE_NO_WARNING on val and old. Set | |
8490 | TREE_ADDRESSABLE on old instead of val. | |
8491 | (emit_side_effect_warnings): Warn only if RHS has !TREE_NO_WARNING. | |
8492 | ||
b581c05c PK |
8493 | 2014-02-07 Prathamesh Kulkarni <bilbotheelffriend@gmail.com> |
8494 | ||
8495 | * c-parser.c (c_parser_get_builtin_args): Replace calls to | |
8496 | C_EXPR_APPEND by vec_safe_push. | |
8497 | * c-tree.h (C_EXPR_APPEND): Remove. | |
8498 | ||
81e5eca8 MP |
8499 | 2014-01-31 Marek Polacek <polacek@redhat.com> |
8500 | ||
8501 | PR c/59963 | |
8502 | * c-typeck.c (convert_lvalue_to_rvalue): Pass vNULL to | |
8503 | build_function_call_vec. | |
8504 | (build_function_call): Likewise. | |
8505 | (build_atomic_assign): Likewise. | |
8506 | (build_function_call_vec): Add arg_loc parameter. Use it. | |
8507 | (convert_arguments): Likewise. | |
8508 | (convert_for_assignment): Rename rhs_loc to expr_loc. | |
8509 | * c-parser.c (c_parser_attributes): Pass NULL to c_parser_expr_list. | |
8510 | (c_parser_objc_keywordexpr): Likewise. | |
8511 | (c_parser_postfix_expression_after_primary): Call | |
8512 | build_function_call_vec with expr_loc rather than op_loc. | |
8513 | Call c_parser_expr_list to fill arg_loc. Pass arg_loc to | |
8514 | build_function_call_vec. | |
8515 | (c_parser_expr_list): Add locations parameter. Fill it with locations | |
8516 | of function arguments. | |
8517 | * c-decl.c (finish_decl): Pass vNULL to build_function_call_vec. | |
8518 | ||
68fca595 MP |
8519 | 2014-01-30 Marek Polacek <polacek@redhat.com> |
8520 | ||
8521 | PR c/59940 | |
8522 | * c-typeck.c (build_function_call_vec): Use loc parameter. | |
8523 | (convert_arguments): Add location parameter. Use it. | |
8524 | (ep_convert_and_check): Likewise. | |
8525 | (build_atomic_assign): Adjust convert_for_assignment call. | |
8526 | (build_modify_expr): Likewise. | |
8527 | (digest_init): Likewise. | |
8528 | (c_finish_return): Likewise. | |
8529 | (build_conditional_expr): Adjust ep_convert_and_check calls. | |
8530 | (convert_for_assignment): Add rhs_loc parameter. Use it. | |
8531 | (build_binary_op): Adjust convert_and_check and ep_convert_and_check | |
8532 | calls. | |
8533 | ||
fa337f3a RB |
8534 | 2014-01-30 Richard Biener <rguenther@suse.de> |
8535 | ||
8536 | PR c/59905 | |
8537 | * c-typeck.c (build_function_call_vec): Do not replace calls | |
8538 | to a function via an incompatible type with a runtime abort. | |
8539 | ||
b72271b9 BI |
8540 | 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com> |
8541 | ||
8542 | * c-parser.c (c_parser_declaration_or_fndef): Replaced | |
8543 | flag_enable_cilkplus with flag_cilkplus. | |
8544 | (c_parser_direct_declarator_inner): Likewise. | |
8545 | (c_parser_attribute_any_word): Likewise. | |
8546 | (c_parser_attributes): Likewise. | |
8547 | (c_parser_compound_statement): Likewise. | |
8548 | (c_parser_statement_after_labels): Likewise. | |
8549 | (c_parser_if_statement): Likewise. | |
8550 | (c_parser_switch_statement): Likewise. | |
8551 | (c_parser_do_statement): Likewise. | |
8552 | (c_parser_for_statement): Likewise. | |
8553 | (c_parser_unary_expression): Likewise. | |
8554 | (c_parser_postfix_expression): Likewise. | |
8555 | (c_parser_postfix_expression_after_primary): Likewise. | |
8556 | (c_parser_postfix_expression_after_primary): Likewise. | |
8557 | (c_parser_omp_clause_name): Likewise. | |
8558 | (c_finish_omp_declare_simd): Likewise. | |
8559 | (c_parser_cilk_verify_simd): Likewise. | |
8560 | * c-typeck.c (build_array_ref): Likewise. | |
8561 | (build_function_call_vec): Likewise. | |
8562 | (convert_arguments): Likewise. | |
8563 | (build_compound_expr): Likewise. | |
8564 | (c_finish_return): Likewise. | |
8565 | (c_finish_if_stmt): Likewise. | |
8566 | (c_finish_loop): Likewise. | |
8567 | (build_binary_op): Likewise. | |
8568 | ||
393e8e8b MP |
8569 | 2014-01-23 Marek Polacek <polacek@redhat.com> |
8570 | ||
8571 | PR c/59846 | |
8572 | * c-typeck.c (parser_build_binary_op): Use location instead of | |
8573 | input_location. | |
8574 | (build_binary_op): Pass location to shorten_compare. | |
8575 | ||
f04dda30 MP |
8576 | 2014-01-23 Marek Polacek <polacek@redhat.com> |
8577 | ||
8578 | PR c/58346 | |
8579 | * c-typeck.c (pointer_diff): Give an error on arithmetic on pointer to | |
8580 | an empty aggregate. | |
8581 | ||
789eadcd MP |
8582 | 2014-01-23 Marek Polacek <polacek@redhat.com> |
8583 | ||
8584 | PR c/59871 | |
8585 | * c-typeck.c (build_compound_expr): Warn even for right-hand operand | |
8586 | of a comma expression. | |
8587 | (emit_side_effect_warnings): Likewise. | |
8588 | ||
40f14e9f BI |
8589 | 2014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com> |
8590 | ||
8591 | PR c/59825 | |
8592 | * c-array-notation.c (expand_array_notation_exprs): Rewrote this | |
8593 | function to use walk_tree and moved a lot of its functionality to | |
8594 | expand_array_notations. | |
8595 | (expand_array_notations): New function. | |
8596 | ||
74558dd9 BI |
8597 | 2014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com> |
8598 | ||
8599 | * c-parser.c (c_finish_omp_declare_simd): Made "cilk simd function" | |
8600 | attribute an attribute without value. | |
8601 | ||
652fea39 JJ |
8602 | 2014-01-23 Jakub Jelinek <jakub@redhat.com> |
8603 | ||
8604 | PR middle-end/58809 | |
8605 | * c-typeck.c (c_finish_omp_clause): Reject MIN_EXPR, MAX_EXPR, | |
8606 | BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR on COMPLEX_TYPEs. | |
8607 | ||
f34f1c87 MP |
8608 | 2014-01-22 Marek Polacek <polacek@redhat.com> |
8609 | ||
8610 | PR c/59891 | |
8611 | * c-typeck.c (build_conditional_expr): Call c_fully_fold instead | |
8612 | of remove_c_maybe_const_expr on op1 and op2. | |
8613 | ||
241f845a JJ |
8614 | 2014-01-15 Jakub Jelinek <jakub@redhat.com> |
8615 | ||
8616 | PR c/58943 | |
8617 | * c-typeck.c (build_modify_expr): For lhs op= rhs, if rhs has side | |
8618 | effects, preevaluate rhs using SAVE_EXPR first. | |
8619 | ||
9a74f20c BI |
8620 | 2014-01-09 Balaji V. Iyer <balaji.v.iyer@intel.com> |
8621 | ||
8622 | PR c++/59631 | |
8623 | * c-parser.c (c_parser_postfix_expression): Replaced consecutive if | |
8624 | statements with if-elseif statements. | |
8625 | ||
96066ce1 MP |
8626 | 2014-01-06 Marek Polacek <polacek@redhat.com> |
8627 | ||
8628 | PR c/57773 | |
8629 | * c-decl.c (check_bitfield_type_and_width): Warn for implementation | |
8630 | defined bit-field types only in ISO C. | |
8631 | ||
23a5b65a RS |
8632 | 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com> |
8633 | ||
8634 | Update copyright years | |
8635 | ||
f9030485 RS |
8636 | 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com> |
8637 | ||
8638 | * c-array-notation.c: Use the standard form for the copyright notice. | |
8639 | ||
41958c28 BI |
8640 | 2013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com> |
8641 | ||
8642 | * c-parser.c (struct c_parser::cilk_simd_fn_tokens): Added new field. | |
8643 | (c_parser_declaration_or_fndef): Added a check if cilk_simd_fn_tokens | |
8644 | field in parser is not empty. If not-empty, call the function | |
8645 | c_parser_finish_omp_declare_simd. | |
8646 | (c_parser_cilk_clause_vectorlength): Modified function to be shared | |
8647 | between SIMD-enabled functions and #pragma simd. Added new parameter. | |
8648 | (c_parser_cilk_all_clauses): Modified the usage of the function | |
8649 | c_parser_cilk_clause_vectorlength as mentioned above. | |
8650 | (c_parser_cilk_simd_fn_vector_attrs): New function. | |
8651 | (c_finish_cilk_simd_fn_tokens): Likewise. | |
8652 | (is_cilkplus_vector_p): Likewise. | |
8653 | (c_parser_omp_clause_name): Added checking for "vectorlength," | |
8654 | "nomask," and "mask" strings in clause name. | |
8655 | (c_parser_omp_all_clauses): Added 3 new case statements: | |
8656 | PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_MASK and | |
8657 | PRAGMA_CILK_CLAUSE_NOMASK. | |
8658 | (c_parser_attributes): Added a cilk_simd_fn_tokens parameter. Added a | |
8659 | check for vector attribute and if so call the function | |
8660 | c_parser_cilk_simd_fn_vector_attrs. Also, when Cilk plus is enabled, | |
8661 | called the function c_finish_cilk_simd_fn_tokens. | |
8662 | (c_finish_omp_declare_simd): Added a check if cilk_simd_fn_tokens in | |
8663 | parser field is non-empty. If so, parse them as you would parse | |
8664 | the omp declare simd pragma. | |
8665 | (c_parser_omp_clause_linear): Added a new bool parm. is_cilk_simd_fn. | |
8666 | Added a check when step is a parameter and flag it as error. | |
8667 | (CILK_SIMD_FN_CLAUSE_MASK): New #define. | |
8668 | (c_parser_cilk_clause_name): Changed pragma_cilk_clause to | |
8669 | pragma_omp_clause. | |
8670 | ||
cef0fd0e TS |
8671 | 2013-12-17 Thomas Schwinge <thomas@codesourcery.com> |
8672 | ||
8673 | * c-parser.c (c_parser_omp_parallel): Fix description. | |
8674 | ||
12893402 BI |
8675 | 2013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com> |
8676 | ||
8677 | * c-objc-common.h (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Remove. | |
8678 | (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise. | |
8679 | (LANG_HOOKS_CILKPLUS_CILKPLUS_GIMPLIFY_SPAWN): Likewise. | |
8680 | * c-typeck.c (cilk_install_body_with_frame_cleanup): New function. | |
8681 | ||
296674db JM |
8682 | 2013-12-04 Joseph Myers <joseph@codesourcery.com> |
8683 | ||
8684 | PR c/52023 | |
8685 | * c-parser.c (c_parser_alignas_specifier): Use | |
8686 | c_sizeof_or_alignof_type instead of c_alignof. | |
8687 | (c_parser_alignof_expression): Likewise, with min_alignof | |
8688 | parameter depending on alignof spelling used. | |
8689 | ||
edd28054 MP |
8690 | 2013-12-04 Marek Polacek <polacek@redhat.com> |
8691 | ||
8692 | PR c/54113 | |
8693 | * c-decl.c (start_function): Don't warn for missing prototype for | |
8694 | inline functions. | |
8695 | ||
da0fc454 MP |
8696 | 2013-12-03 Marek Polacek <polacek@redhat.com> |
8697 | ||
8698 | PR c/59351 | |
8699 | * c-decl.c (build_compound_literal): Allow compound literals with | |
8700 | empty initial value. | |
8701 | ||
4c2ecab0 JM |
8702 | 2013-12-02 Joseph Myers <joseph@codesourcery.com> |
8703 | ||
8704 | PR c/58235 | |
8705 | * c-typeck.c (build_modify_expr): Diagnose assignment to | |
8706 | expression with array type. | |
8707 | ||
340baef7 JM |
8708 | 2013-11-29 Joseph Myers <joseph@codesourcery.com> |
8709 | ||
8710 | PR c/42262 | |
8711 | * c-typeck.c (process_init_element): Do not treat a string as | |
8712 | initializing a whole array when used with a designator for an | |
8713 | individual element. | |
8714 | ||
6763b9f7 JM |
8715 | 2013-11-29 Joseph Myers <joseph@codesourcery.com> |
8716 | ||
8717 | PR c/57574 | |
8718 | * c-decl.c (merge_decls): Clear DECL_EXTERNAL for a definition of | |
8719 | an inline function following a static declaration. | |
8720 | ||
e7bd1de1 JJ |
8721 | 2013-11-28 Jakub Jelinek <jakub@redhat.com> |
8722 | ||
8723 | PR c/59310 | |
8724 | * c-parser.c (c_parser_omp_target): Copy "#pragma omp target" | |
8725 | to p_name before calling c_parser_omp_teams instead of after. | |
8726 | (c_parser_cilk_simd): Remove wrong ATTRIBUTE_UNUSED from parser | |
8727 | argument. Remove unused p_name variable. | |
8728 | ||
0136f8f0 AH |
8729 | 2013-11-27 Aldy Hernandez <aldyh@redhat.com> |
8730 | Jakub Jelinek <jakub@redhat.com> | |
8731 | ||
8732 | * c-decl.c (c_builtin_function_ext_scope): Avoid binding if | |
8733 | external_scope is NULL. | |
8734 | ||
241b71bb TV |
8735 | 2013-11-27 Tom de Vries <tom@codesourcery.com> |
8736 | Marc Glisse <marc.glisse@inria.fr> | |
8737 | ||
8738 | PR c++/59032 | |
8739 | * c-typeck.c (build_unary_op): Allow vector increment and decrement. | |
8740 | ||
2fb9a547 AM |
8741 | 2013-11-22 Andrew MacLeod <amacleod@redhat.com> |
8742 | ||
8743 | * c-typeck.c: Add required include files from gimple.h. | |
8744 | ||
8400e75e DM |
8745 | 2013-11-22 David Malcolm <dmalcolm@redhat.com> |
8746 | ||
8747 | * c-decl.c (define_label, shadow_tag_warned) | |
8748 | (check_bitfield_type_and_width, grokdeclarator, grokparms, | |
8749 | store_parm_decls_newstyle, store_parm_decls_oldstyle) | |
8750 | (declspecs_add_type): Remove use of in_system_header macro. | |
8751 | * c-parser.c (c_parser_unary_expression): Likewise. | |
8752 | * c-typeck.c (store_init_value, process_init_element) | |
8753 | (c_start_case): Likewise. | |
8754 | ||
8755 | * c-decl.c (build_enumerator): Remove use of EXPR_LOC_OR_HERE | |
8756 | macro. | |
8757 | ||
8758 | * c-parser.c (c_parser_set_source_position_from_token): Remove | |
8759 | reference to in_system_header from comment. | |
8760 | ||
386b1f1f RS |
8761 | 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com> |
8762 | ||
8763 | * c-decl.c (grokdeclarator): Update comment to refer to | |
8764 | tree_to_[su]hwi rather than tree_low_cst. | |
8765 | ||
ae7e9ddd RS |
8766 | 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com> |
8767 | ||
8768 | * c-decl.c, c-typeck.c: Replace tree_low_cst (..., 1) with | |
8769 | tree_to_uhwi throughout. | |
8770 | ||
9439e9a1 RS |
8771 | 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com> |
8772 | ||
8773 | * c-parser.c: Replace tree_low_cst (..., 0) with tree_to_shwi | |
8774 | throughout. | |
8775 | ||
9541ffee RS |
8776 | 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com> |
8777 | ||
8778 | * c-parser.c: Replace host_integerp (..., 0) with tree_fits_shwi_p | |
8779 | throughout. | |
8780 | ||
c02065fc AH |
8781 | 2013-11-15 Aldy Hernandez <aldyh@redhat.com> |
8782 | ||
8783 | * c-parser.c (c_parser_cilk_simd): New. | |
8784 | (c_parser_cilk_verify_simd): New. | |
8785 | (c_parser_pragma): Add case for PRAGMA_CILK_SIMD. | |
8786 | (c_parser_omp_for_loop): Add case for NE_EXPR. | |
8787 | Set c_break_label for CILK_SIMD. | |
8788 | (c_parser_cilk_clause_vectorlength): New. | |
8789 | (c_parser_cilk_clause_linear): New. | |
8790 | (c_parser_cilk_clause_name): New. | |
8791 | (c_parser_cilk_all_clauses): New. | |
8792 | * c-typeck.c (build_unary_op): Pass location argument to | |
8793 | readonly_error. | |
8794 | (build_modify_expr): Same. | |
8795 | (build_asm_expr): Same. | |
8796 | (c_finish_bc_stmt): Error on break/continue in loops. | |
8797 | ||
18f429e2 AM |
8798 | 2013-11-14 Andrew MacLeod <amacleod@redhat.com> |
8799 | ||
8800 | * c-typeck.c: Include only gimplify.h and gimple.h as needed. | |
8801 | ||
d8a2d370 DN |
8802 | 2013-11-14 Diego Novillo <dnovillo@google.com> |
8803 | ||
8804 | * c-decl.c: Include print-tree.h. | |
8805 | Include stor-layout.h. | |
8806 | Include varasm.h. | |
8807 | Include attribs.h. | |
8808 | Include stringpool.h. | |
8809 | * c-lang.c: Include fold-const.h. | |
8810 | * c-parser.c: Include stringpool.h. | |
8811 | Include attribs.h. | |
8812 | Include stor-layout.h. | |
8813 | Include varasm.h. | |
8814 | Include trans-mem.h. | |
8815 | * c-typeck.c: Include stor-layout.h. | |
8816 | Include trans-mem.h. | |
8817 | Include varasm.h. | |
8818 | Include stmt.h. | |
8819 | ||
38b7bc7f JM |
8820 | 2013-11-13 Joseph Myers <joseph@codesourcery.com> |
8821 | ||
8822 | * c-tree.h (c_typespec_keyword): Add cts_auto_type. | |
8823 | * c-decl.c (declspecs_add_type, finish_declspecs): Handle | |
8824 | __auto_type. | |
8825 | * c-parser.c (c_token_starts_typename, c_token_starts_declspecs) | |
8826 | (c_parser_attribute_any_word, c_parser_objc_selector): Handle | |
8827 | RID_AUTO_TYPE. | |
8828 | (c_parser_declspecs): Take argument AUTO_TYPE_OK. | |
8829 | (c_parser_declaration_or_fndef, c_parser_struct_declaration) | |
8830 | (c_parser_declarator, c_parser_direct_declarator_inner) | |
8831 | (c_parser_parameter_declaration, c_parser_type_name): All callers | |
8832 | changed. | |
8833 | (c_parser_declaration_or_fndef): Handle declarations with type | |
8834 | determined from the initializer. | |
8835 | ||
45b0be94 AM |
8836 | 2013-11-12 Andrew MacLeod <amacleod@redhat.com> |
8837 | ||
18f429e2 | 8838 | * c-typeck.c: Include gimplify.h. |
45b0be94 | 8839 | |
582d9b50 JM |
8840 | 2013-11-12 Joseph Myers <joseph@codesourcery.com> |
8841 | ||
8842 | * c-tree.h (struct c_declspecs): Add thread_gnu_p field. | |
8843 | * c-parser.c (c_parser_declspecs): Mention _Thread_local in | |
8844 | comment. | |
8845 | * c-decl.c (shadow_tag_warned, grokdeclarator): Mention __thread | |
8846 | or _Thread_local as appropriate in diagnostics. | |
8847 | (build_null_declspecs): Initialize ret->thread_gnu_p. | |
8848 | (declspecs_add_scspec): Handle either __thread or _Thread_local | |
8849 | for RID_THREAD. Diagnose _Thread_local for pre-C11 standards if | |
8850 | pedantic. Do not disallow _Thread_local extern and _Thread_local | |
8851 | static. | |
8852 | ||
267bac10 JM |
8853 | 2013-11-07 Joseph Myers <joseph@codesourcery.com> |
8854 | Andrew MacLeod <amacleod@redhat.com> | |
8855 | ||
8856 | * c-aux-info.c (gen_type): Handle atomic qualifier. | |
8857 | * c-decl.c (validate_proto_after_old_defn): Do not remove atomic | |
8858 | qualifiers when compating types. | |
8859 | (shadow_tag_warned): Handle atomic_p in declspecs. | |
8860 | (quals_from_declspecs): Likewise. | |
8861 | (start_decl): Use c_type_promotes_to when promoting argument | |
8862 | types. | |
8863 | (grokdeclarator): Handle _Atomic. | |
8864 | (get_parm_info): Diagnose any qualifier on "void" as only | |
8865 | parameter. | |
8866 | (store_parm_decls_oldstyle): Do not remove atomic qualifiers when | |
8867 | comparing types. Use c_type_promotes_to when promoting argument | |
8868 | types. | |
8869 | (finish_function): Use c_type_promotes_to when promoting argument | |
8870 | types. | |
8871 | (build_null_declspecs): Handle atomic_p in declspecs. | |
8872 | (declspecs_add_qual): Handle RID_ATOMIC. | |
8873 | * c-parser.c (c_token_starts_typename, c_token_is_qualifier) | |
8874 | (c_token_starts_declspecs): Handle RID_ATOMIC. | |
8875 | (c_parser_declspecs): Handle atomic type specifiers and | |
8876 | qualifiers. | |
8877 | (c_parser_typeof_specifier): Remove const and _Atomic qualifiers | |
8878 | from types of expressions with atomic type. | |
8879 | (c_parser_direct_declarator_inner): Use convert_lvalue_to_rvalue. | |
8880 | (c_parser_attribute_any_word): Handle RID_ATOMIC. | |
8881 | (c_parser_initializer, c_parser_initelt, c_parser_initval) | |
8882 | (c_parser_statement_after_labels, c_parser_switch_statement) | |
8883 | (c_parser_for_statement, c_parser_expr_no_commas) | |
8884 | (c_parser_conditional_expression, c_parser_binary_expression) | |
8885 | (c_parser_cast_expression, c_parser_unary_expression) | |
8886 | (c_parser_postfix_expression) | |
8887 | (c_parser_postfix_expression_after_primary, c_parser_expression): | |
8888 | Use convert_lvalue_to_rvalue. | |
8889 | (c_parser_expression_conv, c_parser_expr_list): Document | |
8890 | conversion of lvalues to rvalues. Use convert_lvalue_to_rvalue. | |
8891 | (c_parser_objc_synchronized_statement): Use | |
8892 | convert_lvalue_to_rvalue. | |
8893 | (c_parser_objc_selector): Handle RID_ATOMIC. | |
8894 | (c_parser_objc_receiver, c_parser_array_notation): Use | |
8895 | convert_lvalue_to_rvalue. | |
8896 | * c-tree.h (ctsk_typeof): Adjust comment to mention use for | |
8897 | _Atomic (type-name). | |
8898 | (struct c_declspecs): Add atomic_p field. | |
8899 | (convert_lvalue_to_rvalue): Declare. | |
8900 | * c-typeck.c (c_type_promotes_to): Promote atomic types to | |
8901 | corresponding atomic types. | |
8902 | (qualify_type): Don't add _Atomic qualifiers from second argument. | |
8903 | (comp_target_types): Do not allow _Atomic mismatches. | |
8904 | (type_lists_compatible_p): Do not remove atomic qualifiers when | |
8905 | comparing types. | |
8906 | (really_atomic_lvalue, convert_lvalue_to_rvalue) | |
8907 | (build_atomic_assign): New functions. | |
8908 | (build_unary_op): Use build_atomic_assign for atomic increment and | |
8909 | decrement. | |
8910 | (build_conditional_expr): Do not treat _Atomic void as a qualified | |
8911 | version of void. | |
8912 | (build_modify_expr): Use build_atomic_assign for atomic LHS. | |
8913 | (find_anonymous_field_with_type, convert_to_anonymous_field) | |
8914 | (convert_for_assignment): Do not remove atomic qualifiers when | |
8915 | comparing types. | |
8916 | (digest_init): Do not accept initialization of arrays of atomic | |
8917 | elements by string constants. | |
8918 | (build_asm_expr): Use convert_lvalue_to_rvalue. | |
8919 | (build_binary_op): Do not treat _Atomic void as a qualified | |
8920 | version of void. | |
8921 | ||
0c249d4b DD |
8922 | 2013-11-06 DJ Delorie <dj@redhat.com> |
8923 | ||
8924 | * c-decl.c (locate_old_decl): If a previous conflicting decl is | |
8925 | both explicit and builtin, print the location of the explicit one. | |
8926 | ||
6d7f7e0a TB |
8927 | 2013-11-05 Tobias Burnus <burnus@net-b.de> |
8928 | ||
8929 | * c-parser.c (c_parser_omp_for, c_parser_omp_parallel, | |
8930 | c_parser_omp_distribute, c_parser_omp_teams, | |
8931 | c_parser_omp_target, c_parser_omp_declare): Handle | |
8932 | -fopenmp-simd. | |
8933 | ||
b906f4ca MP |
8934 | 2013-11-03 Marek Polacek <polacek@redhat.com> |
8935 | ||
8936 | * c-decl.c (grokdeclarator): Add VLA instrumentation. | |
8937 | ||
ee1d5a02 JJ |
8938 | 2013-11-01 Jakub Jelinek <jakub@redhat.com> |
8939 | ||
8940 | * c-typeck.c (c_finish_omp_clauses) <case OMP_CLAUSE_UNIFORM>: Go to | |
8941 | check_dup_generic at the end, unless remove is true. | |
8942 | (c_finish_omp_clauses) <case OMP_CLAUSE_REDUCTION>: Add break; after | |
8943 | remove = true;. | |
8944 | (c_finish_omp_clauses) <case OMP_CLAUSE_COPYIN>: Likewise. | |
8945 | ||
5a9785fb JJ |
8946 | 2013-10-31 Jakub Jelinek <jakub@redhat.com> |
8947 | ||
8948 | * c-typeck.c (c_finish_omp_clauses): Diagnose aligned clause | |
8949 | with decl that is not pointer nor array. | |
8950 | ||
939b37da BI |
8951 | 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com> |
8952 | ||
8953 | * c-decl.c (finish_function): Added a call for insert_cilk_frame when | |
8954 | a spawning function is found. | |
8955 | * c-objc-common.h (LANG_HOOKS_CILKPLUS_GIMPLIFY_SPAWN): New #define. | |
8956 | (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Likewise. | |
8957 | (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise. | |
8958 | * c-parser.c (c_parser_statement_after_labels): Added RID_CILK_SYNC | |
8959 | case. | |
8960 | (c_parser_postfix_expression): Added RID_CILK_SPAWN case. | |
8961 | * c-typeck.c (build_compound_expr): Reject _Cilk_spawn in a comma | |
8962 | expr. | |
8963 | (c_finish_return): Added a check to reject _Cilk_spawn in return | |
8964 | expression. | |
8965 | (build_cilk_spawn): New function. | |
8966 | (build_cilk_sync): Likewise. | |
8967 | * Makefile.in (c-decl.o): Added cilk.h in dependency list. | |
ab20d992 | 8968 | |
d4af74d4 TB |
8969 | 2013-10-27 Tobias Burnus <burnus@net-b.de> |
8970 | ||
8971 | PR other/33426 | |
8972 | * c-parser.c (c_parser_while_statement, c_parser_while_statement, | |
8973 | c_parser_pragma): Add GCC ivdep support to 'do' and 'while'. | |
8974 | (c_parser_statement_after_labels): Update calls. | |
8975 | ||
d73749df | 8976 | 2013-10-24 Tobias Burnus <burnus@net-b.de> |
8170608b TB |
8977 | |
8978 | PR other/33426 | |
8979 | * c-parser.c (c_parser_pragma, c_parser_for_statement): | |
8980 | Handle PRAGMA_IVDEP. | |
8981 | (c_parser_statement_after_labels): Update call. | |
8982 | ||
f28aa681 MP |
8983 | 2013-10-24 Marek Polacek <polacek@redhat.com> |
8984 | ||
8985 | * c-parser.c (c_parser_struct_declaration): Add a comment. | |
8986 | (c_parser_declarator): Don't allow _Alignas here. | |
8987 | ||
0645c1a2 AM |
8988 | 2013-10-17 Andrew MacLeod <amacleod@redhat.com> |
8989 | ||
8990 | * c-parser.c: Include omp-low.h. | |
8991 | * c-typeck.c: Likewise. | |
8992 | ||
568a31f2 MP |
8993 | 2013-10-17 Marek Polacek <polacek@redhat.com> |
8994 | ||
8995 | PR c/58267 | |
8996 | * c-parser.c (c_parser_declspecs): Add alignspec_ok parameter. | |
8997 | Document syntax of the array-declarator. | |
8998 | (c_parser_declspecs) <RID_ALIGNAS>: Bail out if alignment specs | |
8999 | are not permitted. | |
9000 | (c_parser_declaration_or_fndef): Adjust c_parser_declspecs call. | |
9001 | (c_parser_struct_declaration): Likewise. | |
9002 | (c_parser_declarator): Likewise. | |
9003 | (c_parser_direct_declarator_inner): Likewise. | |
9004 | (c_parser_parameter_declaration): Likewise. | |
9005 | (c_parser_type_name): Likewise. | |
9006 | ||
acf0174b JJ |
9007 | 2013-10-11 Jakub Jelinek <jakub@redhat.com> |
9008 | ||
9009 | * c-lang.h (current_omp_declare_target_attribute): New extern | |
9010 | decl. | |
9011 | * c-parser.c: Include c-lang.h. | |
9012 | (struct c_parser): Change tokens to c_token *. | |
9013 | Add tokens_buf field. Change tokens_avail type to unsigned int. | |
9014 | (c_parser_consume_token): If parser->tokens isn't | |
9015 | &parser->tokens_buf[0], increment parser->tokens. | |
9016 | (c_parser_consume_pragma): Likewise. | |
9017 | (enum pragma_context): Add pragma_struct and pragma_param. | |
9018 | (c_parser_external_declaration): Adjust | |
9019 | c_parser_declaration_or_fndef caller. | |
9020 | (c_parser_declaration_or_fndef): Add omp_declare_simd_clauses | |
9021 | argument, if it is non-vNULL vector, call c_finish_omp_declare_simd. | |
9022 | Adjust recursive call. | |
9023 | (c_parser_struct_or_union_specifier): Use pragma_struct instead | |
9024 | of pragma_external. | |
9025 | (c_parser_parameter_declaration): Use pragma_param instead of | |
9026 | pragma_external. | |
9027 | (c_parser_compound_statement_nostart, c_parser_label, | |
9028 | c_parser_for_statement): Adjust | |
9029 | c_parser_declaration_or_fndef callers. | |
9030 | (c_parser_expr_no_commas): Add omp_atomic_lhs argument, pass | |
9031 | it through to c_parser_conditional_expression. | |
9032 | (c_parser_conditional_expression): Add omp_atomic_lhs argument, | |
9033 | pass it through to c_parser_binary_expression. Adjust recursive | |
9034 | call. | |
9035 | (c_parser_binary_expression): Remove prec argument, add | |
9036 | omp_atomic_lhs argument instead. Always start from PREC_NONE, if | |
9037 | omp_atomic_lhs is non-NULL and one of the arguments of toplevel | |
9038 | binop matches it, use build2 instead of parser_build_binary_op. | |
9039 | (c_parser_pragma): Handle PRAGMA_OMP_CANCEL, | |
9040 | PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_TARGET, | |
9041 | PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_DECLARE_REDUCTION. | |
9042 | Handle pragma_struct and pragma_param the same as pragma_external. | |
9043 | (c_parser_omp_clause_name): Parse new OpenMP 4.0 clause names. | |
9044 | (c_parser_omp_variable_list): Parse array sections for | |
9045 | OMP_CLAUSE_{DEPEND,MAP,TO,FROM} clauses. | |
9046 | (c_parser_omp_clause_collapse): Fully fold collapse expression. | |
9047 | (c_parser_omp_clause_reduction): Handle user defined reductions. | |
9048 | (c_parser_omp_clause_branch, c_parser_omp_clause_cancelkind, | |
9049 | c_parser_omp_clause_num_teams, c_parser_omp_clause_thread_limit, | |
9050 | c_parser_omp_clause_aligned, c_parser_omp_clause_linear, | |
9051 | c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen, | |
9052 | c_parser_omp_clause_depend, c_parser_omp_clause_map, | |
9053 | c_parser_omp_clause_device, c_parser_omp_clause_dist_schedule, | |
9054 | c_parser_omp_clause_proc_bind, c_parser_omp_clause_to, | |
9055 | c_parser_omp_clause_from, c_parser_omp_clause_uniform): New functions. | |
9056 | (c_parser_omp_all_clauses): Add finish_p argument. Don't call | |
9057 | c_finish_omp_clauses if it is false. Handle new OpenMP 4.0 clauses. | |
9058 | (c_parser_omp_atomic): Parse seq_cst clause, pass true if it is | |
9059 | present to c_finish_omp_atomic. Handle OpenMP 4.0 atomic forms. | |
9060 | (c_parser_omp_for_loop): Add CODE argument, pass it through | |
9061 | to c_finish_omp_for. Change last argument to cclauses, | |
9062 | and adjust uses to grab parallel clauses from the array of all | |
9063 | the split clauses. Adjust c_parser_binary_expression, | |
9064 | c_parser_declaration_or_fndef and c_finish_omp_for callers. | |
9065 | (omp_split_clauses): New function. | |
9066 | (c_parser_omp_simd): New function. | |
9067 | (c_parser_omp_for): Add p_name, mask and cclauses arguments. | |
9068 | Allow the function to be called also when parsing combined constructs, | |
9069 | and call c_parser_omp_simd when parsing for simd. | |
9070 | (c_parser_omp_sections_scope): If section-sequence doesn't start with | |
9071 | #pragma omp section, require exactly one structured-block instead of | |
9072 | sequence of statements. | |
9073 | (c_parser_omp_sections): Add p_name, mask and cclauses arguments. | |
9074 | Allow the function to be called also when parsing combined constructs. | |
9075 | (c_parser_omp_parallel): Add p_name, mask and cclauses arguments. | |
9076 | Allow the function to be called also when parsing combined | |
9077 | constructs. | |
9078 | (c_parser_omp_taskgroup, c_parser_omp_cancel, | |
9079 | c_parser_omp_cancellation_point, c_parser_omp_distribute, | |
9080 | c_parser_omp_teams, c_parser_omp_target_data, | |
9081 | c_parser_omp_target_update, c_parser_omp_target, | |
9082 | c_parser_omp_declare_simd, c_finish_omp_declare_simd, | |
9083 | c_parser_omp_declare_target, c_parser_omp_end_declare_target, | |
9084 | c_parser_omp_declare_reduction, c_parser_omp_declare): New functions. | |
9085 | (c_parser_omp_construct): Add p_name and mask vars. Handle | |
9086 | PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_SIMD, PRAGMA_OMP_TASKGROUP, | |
9087 | PRAGMA_OMP_TEAMS. Adjust c_parser_omp_for, c_parser_omp_parallel | |
9088 | and c_parser_omp_sections callers. | |
9089 | (c_parse_file): Initialize tparser.tokens and the_parser->tokens here. | |
9090 | (OMP_FOR_CLAUSE_MASK, OMP_SECTIONS_CLAUSE_MASK, | |
9091 | OMP_SINGLE_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1. | |
9092 | (OMP_PARALLEL_CLAUSE_MASK): Likewise. Add OMP_CLAUSE_PROC_BIND. | |
9093 | (OMP_TASK_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1. Add | |
9094 | OMP_CLAUSE_DEPEND. | |
9095 | (OMP_SIMD_CLAUSE_MASK, OMP_CANCEL_CLAUSE_MASK, | |
9096 | OMP_CANCELLATION_POINT_CLAUSE_MASK, OMP_DISTRIBUTE_CLAUSE_MASK, | |
9097 | OMP_TEAMS_CLAUSE_MASK, OMP_TARGET_DATA_CLAUSE_MASK, | |
9098 | OMP_TARGET_UPDATE_CLAUSE_MASK, OMP_TARGET_CLAUSE_MASK, | |
9099 | OMP_DECLARE_SIMD_CLAUSE_MASK): Define. | |
9100 | * c-typeck.c: Include tree-inline.h. | |
9101 | (c_finish_omp_cancel, c_finish_omp_cancellation_point, | |
9102 | handle_omp_array_sections_1, handle_omp_array_sections, | |
9103 | c_clone_omp_udr, c_find_omp_placeholder_r): New functions. | |
9104 | (c_finish_omp_clauses): Handle new OpenMP 4.0 clauses and | |
9105 | user defined reductions. | |
9106 | (c_tree_equal): New function. | |
9107 | * c-tree.h (temp_store_parm_decls, temp_pop_parm_decls, | |
9108 | c_finish_omp_cancel, c_finish_omp_cancellation_point, c_tree_equal, | |
9109 | c_omp_reduction_id, c_omp_reduction_decl, c_omp_reduction_lookup, | |
9110 | c_check_omp_declare_reduction_r): New prototypes. | |
9111 | * c-decl.c (current_omp_declare_target_attribute): New variable. | |
9112 | (c_decl_attributes): New function. | |
9113 | (start_decl, start_function): Use it instead of decl_attributes. | |
9114 | (temp_store_parm_decls, temp_pop_parm_decls, c_omp_reduction_id, | |
9115 | c_omp_reduction_decl, c_omp_reduction_lookup, | |
9116 | c_check_omp_declare_reduction_r): New functions. | |
9117 | ||
0a6c2227 TT |
9118 | 2013-09-25 Tom Tromey <tromey@redhat.com> |
9119 | ||
9120 | * Make-lang.in (c/gccspec.o): Remove. | |
9121 | (CFLAGS-c/gccspec.o): New variable. | |
9122 | (cc1-checksum.o, C_TREE_H, c/c-aux-info.o, c/c-convert.o) | |
9123 | (c/c-decl.o, c/c-errors.o, c/c-lang.o, c/c-objc-common.o) | |
9124 | (c/c-parser.o, c/c-typeck.o, c/c-array-notation.o): Remove. | |
9125 | ||
f3bc55f0 TT |
9126 | 2013-09-25 Tom Tromey <tromey@redhat.com> |
9127 | ||
9128 | * Make-lang.in (c/gccspec.o): Don't use subshell. | |
9129 | ||
a24d975c MP |
9130 | 2013-09-18 Marek Polacek <polacek@redhat.com> |
9131 | ||
9132 | PR sanitize/58443 | |
9133 | * c-typeck.c (build_binary_op): Properly honor -fsanitize options. | |
9134 | Remove unnecessary check. | |
9135 | ||
ce6923c5 MP |
9136 | 2013-09-18 Marek Polacek <polacek@redhat.com> |
9137 | ||
9138 | PR sanitizer/58411 | |
9139 | * c-typeck.c (build_binary_op): Don't sanitize function if it has the | |
9140 | no_sanitize_undefined attribute. | |
9141 | ||
a1e51df9 KT |
9142 | 2013-09-13 Kai Tietz <ktietz@redhat.com> |
9143 | ||
9144 | PR target/57848 | |
9145 | * c-decl.c (c_builtin_function_ext_scope): Remove | |
9146 | wrong assumption that it is never called on prexisting | |
9147 | symbol. | |
9148 | ||
0af94e6f JR |
9149 | 2013-09-08 Joern Rennecke <joern.rennecke@embecosm.com> |
9150 | ||
9151 | * c-typeck.c (build_binary_op): Use vector_types_compatible_elements_p. | |
9152 | ||
20059c8b GDR |
9153 | 2013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net> |
9154 | ||
9155 | * c-objc-common.c (c_tree_printer): Tidy. | |
9156 | ||
de5a5fa1 MP |
9157 | 2013-08-30 Marek Polacek <polacek@redhat.com> |
9158 | ||
9159 | * c-typeck.c (build_binary_op): Add division by zero and shift | |
9160 | instrumentation. | |
9161 | ||
2531a1d9 | 9162 | 2013-08-26 Joern Rennecke <joern.rennecke@embecosm.com> |
0fdd4508 | 9163 | Joseph Myers <joseph@codesourcery.com> |
2531a1d9 | 9164 | |
6e2bcc98 | 9165 | PR c/35649 |
2531a1d9 JR |
9166 | * c-typeck.c (c_common_type): Prefer double_type_node over |
9167 | other REAL_TYPE types with the same precision. | |
9168 | (convert_arguments): Likewise. | |
9169 | ||
025311c4 GDR |
9170 | 2013-08-23 Gabriel Dos Reis <gdr@integrable-solutions.net> |
9171 | ||
9172 | * c-objc-common.c (c_tree_printer): Document the nature of the cast. | |
9173 | (c_initialize_diagnostics): Call a destructor for the early printer. | |
9174 | ||
da6ca2b5 GDR |
9175 | 2013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net> |
9176 | ||
9177 | * c-objc-common.c (c_initialize_diagnostics): Simplify C pretty | |
9178 | printer initialization. | |
9179 | ||
318cda85 | 9180 | 2013-08-19 Balaji V. Iyer <balaji.v.iyer@intel.com> |
da6ca2b5 | 9181 | |
318cda85 BI |
9182 | PR c/57490 |
9183 | * c-array-notation.c (fix_conditional_array_notations_1): Added a | |
9184 | check for truth values. | |
9185 | (expand_array_notation_exprs): Added truth values case. Removed an | |
9186 | unwanted else. Added for-loop to walk through subtrees in default | |
9187 | case. | |
9188 | ||
b066401f GDR |
9189 | 2013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net> |
9190 | ||
9191 | * c-objc-common.c (c_initialize_diagnostics): Don't call pp_base. | |
9192 | ||
fb48aadc JM |
9193 | 2013-07-23 Joseph Myers <joseph@codesourcery.com> |
9194 | ||
9195 | * c-parser.c (struct c_generic_association): Fix typo. | |
9196 | ||
433cc7b0 TT |
9197 | 2013-07-23 Tom Tromey <tromey@redhat.com> |
9198 | Joseph Myers <joseph@codesourcery.com> | |
9199 | ||
9200 | * c-parser.c (struct c_generic_association): New. | |
9201 | (c_generic_association_d): New typedef. | |
9202 | (c_parser_generic_selection): New function. | |
9203 | (c_parser_postfix_expression): Handle RID_GENERIC. | |
9204 | ||
26d40c3d JM |
9205 | 2013-07-13 Jason Merrill <jason@redhat.com> |
9206 | ||
9207 | PR c++/57793 | |
9208 | * c-decl.c (finish_struct): Check for too-large class. | |
9209 | ||
ecdbd01a | 9210 | 2013-07-04 Joern Rennecke <joern.rennecke@embecosm.com> |
40d3d530 JR |
9211 | |
9212 | PR c/57821 | |
9213 | * c-typeck.c (set_init_index): When folding, check for index overflow. | |
9214 | ||
1141ed3f BI |
9215 | 2013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9216 | ||
9217 | * c-parser.c (c_parser_array_notation): Removed rejection of array | |
9218 | notations in an array of function pointers. | |
9219 | ||
713b46fa BI |
9220 | 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9221 | ||
9222 | * c-array-notation.c (make_triplet_val_inv): New function. | |
9223 | (create_cmp_incr): Likewise. | |
9224 | (create_array_refs): Likewise. | |
9225 | (fix_builtin_array_notation_fn): Replaced all mallocs with tree vec. | |
9226 | Also modularized common parts between functions and called the function. | |
9227 | (build_array_notation_expr): Likewise. | |
9228 | (fix_conditional_array_notations_1): Likewise. | |
9229 | (fix_array_notation_expr): Likewise. | |
9230 | (fix_array_notation_call_expr): Likewise. | |
9231 | ||
92f20202 MP |
9232 | 2013-06-18 Marek Polacek <polacek@redhat.com> |
9233 | ||
9234 | PR c/57630 | |
9235 | * c-decl.c (check_for_loop_decls): Improve diagnostics messages. | |
9236 | ||
73a23b06 BI |
9237 | 2013-06-12 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9238 | ||
9239 | * c-array-notation.c (build_array_notation_expr): Reject array notation | |
9240 | mismatch between LHS and RHS even inside a call_expr. Also, removed | |
9241 | a couple while statements that were dead code. | |
9242 | ||
00b8517d BI |
9243 | 2013-06-10 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9244 | ||
9245 | * c-array-notation.c (fix_builtin_array_notation_fn): Fully folded | |
9246 | excessive precision expressions in function parameters. Also removed | |
9247 | couple unwanted while statements. | |
9248 | ||
1509bdda BI |
9249 | 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9250 | ||
9251 | * c-array-notation.c (expand_array_notation_exprs): Added | |
9252 | ARRAY_NOTATION_REF case. | |
ab20d992 | 9253 | |
d60f1706 BI |
9254 | 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9255 | ||
9256 | * c-array-notation.c (length_mismatch_in_expr_p): Moved this | |
9257 | function to c-family/array-notation-common.c. | |
9258 | (is_cilkplus_reduce_builtin): Likewise. | |
9259 | (find_rank): Likewise. | |
9260 | (extract_array_notation_exprs): Likewise. | |
9261 | (replace_array_notations): Likewise. | |
9262 | (find_inv_trees): Likewise. | |
9263 | (replace_inv_trees): Likewise. | |
9264 | (contains_array_notation_expr): Likewise. | |
9265 | (find_correct_array_notation_type): Likewise. | |
9266 | (replace_invariant_exprs): Initialized additional_tcodes to NULL. | |
9267 | (struct inv_list): Moved this to c-family/array-notation-common.c. | |
9268 | * c-tree.h (is_cilkplus_builtin_reduce): Remove prototype. | |
ab20d992 | 9269 | |
6d6efbb3 BI |
9270 | 2013-06-05 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9271 | ||
9272 | * c-typeck.c (convert_arguments): Moved checking of builtin cilkplus | |
9273 | reduction functions outside the for-loop. Added a check if the fundecl | |
9274 | is non-NULL. Finally, removed an unwanted if-statement, and made the | |
9275 | body unconditional. | |
9276 | ||
25c22937 BI |
9277 | 2013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9278 | ||
9279 | * c-typeck.c (c_finish_if_stmt): Added a check to see if the rank of the | |
9280 | condition of the if-statement matches the rank of else-block and then- | |
9281 | block when array notations are used. | |
9282 | * c-parser.c (c_parser_declaration_or_fndef): Expanded array notation | |
9283 | expression after the entire function body is parsed. | |
9284 | (c_parser_expr_no_commas): Delayed creating array notation expressions | |
9285 | to the end of function parsing. | |
9286 | * c-array-notation.c (fix_conditional_array_notations_1): Expanded the | |
9287 | whole if-statement instead of just the condition. | |
ab20d992 | 9288 | (expand_array_notation_exprs): Added MODIFY_EXPR case. |
25c22937 | 9289 | |
edd25645 BI |
9290 | 2013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9291 | ||
9292 | PR c/57474 | |
9293 | * c-array-notation.c (build_array_notation_expr): Initialized rhs_length | |
9294 | array to NULL_TREE if they are unused. Also added a check for the | |
9295 | field to be NULL before its fields are used in future. | |
ab20d992 | 9296 | |
065ce7f1 RO |
9297 | 2013-05-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> |
9298 | ||
9299 | PR bootstrap/57450 | |
9300 | * c-array-notation.c (length_mismatch_in_expr_p): Use absu_hwi. | |
9301 | (build_array_notation_expr): Likewise. | |
9302 | ||
36536d79 BI |
9303 | 2013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com> |
9304 | ||
9305 | * c-typeck.c (build_array_ref): Added a check to see if array's | |
9306 | index is greater than one. If true, then emit an error. | |
9307 | (build_function_call_vec): Exclude error reporting and checking | |
9308 | for builtin array-notation functions. | |
9309 | (convert_arguments): Likewise. | |
9310 | (c_finish_return): Added a check for array notations as a return | |
9311 | expression. If true, then emit an error. | |
9312 | (c_finish_loop): Added a check for array notations in a loop | |
9313 | condition. If true then emit an error. | |
9314 | (lvalue_p): Added a ARRAY_NOTATION_REF case. | |
9315 | (build_binary_op): Added a check for array notation expr inside | |
9316 | op1 and op0. If present, we call another function to find correct | |
9317 | type. | |
9318 | * Make-lang.in (C_AND_OBJC_OBJS): Added c-array-notation.o. | |
9319 | * c-parser.c (c_parser_compound_statement): Check if array | |
9320 | notation code is used in tree, if so, then transform them into | |
9321 | appropriate C code. | |
9322 | (c_parser_expr_no_commas): Check if array notation is used in LHS | |
9323 | or RHS, if so, then build array notation expression instead of | |
9324 | regular modify. | |
9325 | (c_parser_postfix_expression_after_primary): Added a check for | |
9326 | colon(s) after square braces, if so then handle it like an array | |
9327 | notation. Also, break up array notations in unary op if found. | |
9328 | (c_parser_direct_declarator_inner): Added a check for array | |
9329 | notation. | |
9330 | (c_parser_compound_statement): Added a check for array notation in | |
9331 | a stmt. If one is present, then expand array notation expr. | |
9332 | (c_parser_if_statement): Likewise. | |
9333 | (c_parser_switch_statement): Added a check for array notations in | |
9334 | a switch statement's condition. If true, then output an error. | |
9335 | (c_parser_while_statement): Similarly, but for a while. | |
9336 | (c_parser_do_statement): Similarly, but for a do-while. | |
9337 | (c_parser_for_statement): Similarly, but for a for-loop. | |
9338 | (c_parser_unary_expression): Check if array notation is used in a | |
9339 | pre-increment or pre-decrement expression. If true, then expand | |
9340 | them. | |
9341 | (c_parser_array_notation): New function. | |
9342 | * c-array-notation.c: New file. | |
9343 | * c-tree.h (is_cilkplus_reduce_builtin): Protoize. | |
ab20d992 | 9344 | |
cd192ccc MS |
9345 | 2013-05-23 Mike Stump <mikestump@comcast.net> |
9346 | ||
9347 | * c-typeck.c (convert_for_assignment): Handle references to memory | |
9348 | spaces better. | |
9349 | ||
427b248d JM |
9350 | 2013-05-16 Jason Merrill <jason@redhat.com> |
9351 | ||
9352 | * Make-lang.in (cc1$(exeext)): Use link mutex. | |
9353 | ||
44d90fe1 PC |
9354 | 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com> |
9355 | ||
9356 | * c-typeck.c (pointer_diff): Change -Wpointer-arith pedwarns | |
9357 | to simply use OPT_Wpointer_arith. | |
9358 | (build_unary_op): Likewise. | |
9359 | ||
4e7d7b3d JJ |
9360 | 2013-04-03 Jakub Jelinek <jakub@redhat.com> |
9361 | ||
9362 | PR c/19449 | |
9363 | * c-parser.c (c_parser_get_builtin_args): Add choose_expr_p | |
9364 | argument. If set, or it temporarily for parsing of the first | |
9365 | argument into force_folding_builtin_constant_p. | |
9366 | (c_parser_postfix_expression): Adjust callers. | |
9367 | ||
839b422f RB |
9368 | 2013-03-21 Richard Biener <rguenther@suse.de> |
9369 | ||
9370 | * c-objc-common.c (c_tree_printer): Use DECL_HAS_DEBUG_EXPR_P | |
9371 | instead of DECL_DEBUG_EXPR_IS_FROM. Guard properly. | |
9372 | ||
2ee028f1 MP |
9373 | 2013-02-12 Marek Polacek <polacek@redhat.com> |
9374 | ||
9375 | PR c/44938 | |
9376 | * c-parser.c (c_parser_postfix_expression_after_primary): Initialize | |
9377 | origtypes to NULL. | |
9378 | ||
8824edff JJ |
9379 | 2013-01-24 Jakub Jelinek <jakub@redhat.com> |
9380 | ||
9381 | PR c/56078 | |
9382 | * c-typeck.c (set_nonincremental_init_from_string): If | |
9383 | constructor_max_index is NULL, treat it as if tree_int_cst_lt | |
9384 | returned false. | |
9385 | (process_init_element): Likewise. | |
9386 | ||
eadd3d0d JJ |
9387 | 2012-12-20 Jakub Jelinek <jakub@redhat.com> |
9388 | ||
9389 | PR c++/55619 | |
9390 | * c-parser.c (c_parser_asm_operands): Remove CONVERT_P | |
9391 | argument, don't call default_function_array_conversion | |
9392 | nor c_fully_fold here. | |
9393 | (c_parser_asm_statement): Adjust callers. | |
9394 | * c-typeck.c (build_asm_expr): Call c_fully_fold on inputs | |
9395 | and outputs here, and call default_function_array_conversion | |
9396 | on inputs that don't need to be addressable. | |
9397 | ||
f8a93a2e JJ |
9398 | 2012-12-18 Jakub Jelinek <jakub@redhat.com> |
9399 | ||
9400 | PR c/39464 | |
9401 | * c-typeck.c (convert_for_assignment): For -Wpointer-sign | |
9402 | warning require that both c_common_unsigned_type as well as | |
9403 | c_common_signed_type is the same for both mvl and mvr types. | |
9404 | ||
9771b263 DN |
9405 | 2012-11-16 Diego Novillo <dnovillo@google.com> |
9406 | ||
9407 | Adjust for new vec API (http://gcc.gnu.org/wiki/cxx-conversion/cxx-vec) | |
9408 | ||
9409 | * c-common.c: Use new vec API in vec.h. | |
9410 | * c-common.h: Likewise. | |
9411 | * c-gimplify.c: Likewise. | |
9412 | * c-pragma.c: Likewise. | |
9413 | * c-pretty-print.c: Likewise. | |
9414 | * c-pretty-print.h: Likewise. | |
9415 | * c-semantics.c: Likewise. | |
9416 | * c-decl.c: Likewise. | |
9417 | * c-parser.c: Likewise. | |
9418 | * c-tree.h: Likewise. | |
9419 | * c-typeck.c: Likewise. | |
9420 | ||
880661a4 JW |
9421 | 2012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com> |
9422 | ||
9423 | PR c++/54930 | |
9424 | * c-typeck.c (c_finish_return): Use OPT_Wreturn_local_addr. | |
9425 | ||
077d1abe MLI |
9426 | 2012-10-29 Manuel López-Ibáñez <manu@gcc.gnu.org> |
9427 | ||
9428 | PR c/53066 | |
9429 | * c-decl.c (warn_if_shadowing): Do not warn if a variable | |
9430 | shadows a function, unless the variable is a function or a | |
9431 | pointer-to-function. | |
9432 | ||
3a785c97 JJ |
9433 | 2012-10-12 Jakub Jelinek <jakub@redhat.com> |
9434 | ||
9435 | PR c/54381 | |
9436 | * c-parser.c (struct c_tree_loc_pair): Removed. | |
9437 | (c_parser_expr_list): Remove struct c_tree_loc_pair * argument, | |
9438 | add location_t * and tree * arguments, fill in array of 3 | |
9439 | sizeof_arg trees and corresponding locs. | |
9440 | (c_parser_attributes, c_parser_objc_keywordexpr): Adjust | |
9441 | c_parser_expr_list callers. | |
9442 | (c_parser_postfix_expression_after_primary): Likewise. Pass | |
9443 | array of 3 sizeof_arg trees and locs (corresponding to first | |
9444 | 3 arguments) to sizeof_pointer_memaccess_warning. | |
9445 | ||
703c8606 LC |
9446 | 2012-10-09 Lawrence Crowl <crowl@google.com> |
9447 | ||
9448 | * Make-lang.in (c-decl.o): Add dependence on hash-table.h. | |
9449 | * c-decl.c (detect_field_duplicates_hash): Change to new type-safe | |
9450 | hash table. | |
9451 | ||
5d9de0d0 PC |
9452 | 2012-10-09 Paolo Carlini <paolo.carlini@oracle.com> |
9453 | ||
9454 | PR c++/54194 | |
9455 | * c-typeck.c (parser_build_binary_op): Update warn_about_parentheses | |
9456 | call. | |
9457 | ||
a212e43f MG |
9458 | 2012-10-09 Marc Glisse <marc.glisse@inria.fr> |
9459 | ||
9460 | PR c++/54427 | |
9461 | * c-typeck.c: Include c-common.h. | |
9462 | (enum stv_conv): Moved to c-common.h. | |
9463 | (scalar_to_vector): Moved to c-common.c. | |
9464 | (build_binary_op): Adapt to scalar_to_vector's new prototype. | |
9465 | * Make-lang.in: c-typeck.c depends on c-common.h. | |
9466 | ||
3b78de56 AC |
9467 | 2012-10-04 Arnaud Charlet <charlet@adacore.com> |
9468 | ||
9469 | * c-decl.c (c_write_global_declarations): Fix handling of | |
9470 | -fdump-ada-spec*. | |
9471 | ||
78c60e3d SS |
9472 | 2012-09-30 Sharad Singhai <singhai@google.com> |
9473 | ||
9474 | * c-decl.c (c_write_global_declarations): Use a different method | |
9475 | to determine if the dump has ben initialized. | |
9476 | ||
9f33203d JM |
9477 | 2012-09-14 Joseph Myers <joseph@codesourcery.com> |
9478 | ||
9479 | PR c/54552 | |
9480 | * c-typeck.c (c_cast_expr): When casting to a type requiring | |
9481 | C_MAYBE_CONST_EXPR to be created, pass the inner expression to | |
9482 | c_fully_fold first. | |
9483 | ||
a27d595d JM |
9484 | 2012-09-14 Joseph Myers <joseph@codesourcery.com> |
9485 | ||
9486 | PR c/54103 | |
9487 | * c-typeck.c (build_unary_op): Pass original argument of | |
9488 | TRUTH_NOT_EXPR to c_objc_common_truthvalue_conversion, then remove | |
9489 | any C_MAYBE_CONST_EXPR, if it has integer operands. | |
9490 | (build_binary_op): Pass original arguments of TRUTH_ANDIF_EXPR, | |
9491 | TRUTH_ORIF_EXPR, TRUTH_AND_EXPR, TRUTH_OR_EXPR and TRUTH_XOR_EXPR | |
9492 | to c_objc_common_truthvalue_conversion, then remove any | |
9493 | C_MAYBE_CONST_EXPR, if they have integer operands. Use | |
9494 | c_objc_common_truthvalue_conversion not | |
9495 | c_common_truthvalue_conversion. | |
9496 | (c_objc_common_truthvalue_conversion): Build NE_EXPR directly and | |
9497 | call note_integer_operands for arguments with integer operands | |
9498 | that are not integer constants. | |
9499 | ||
9feb29df JJ |
9500 | 2012-09-13 Jakub Jelinek <jakub@redhat.com> |
9501 | ||
9502 | PR c/54559 | |
9503 | * c-typeck.c (c_finish_return): Do convert to BOOLEAN_TYPE or | |
9504 | COMPLEX_TYPE with in_late_binary_op set temporarily to true. | |
9505 | ||
d409320c JJ |
9506 | 2012-08-31 Jakub Jelinek <jakub@redhat.com> |
9507 | ||
9508 | PR c/54428 | |
9509 | * c-convert.c (convert): Don't call fold_convert_loc if | |
9510 | TYPE_MAIN_VARIANT of a COMPLEX_TYPE is the same, unless e | |
9511 | is a COMPLEX_EXPR. Remove TYPE_MAIN_VARIANT check from | |
9512 | COMPLEX_TYPE -> COMPLEX_TYPE conversion. | |
9513 | ||
6265d07c JJ |
9514 | 2012-08-24 Jakub Jelinek <jakub@redhat.com> |
9515 | ||
9516 | PR c/54355 | |
9517 | * c-decl.c (c_parser_label): Pass true as nested and fix up comments | |
9518 | for nested and empty_ok arguments in the call to | |
9519 | c_parser_declaration_or_fndef. | |
9520 | ||
1a4049e7 JJ |
9521 | 2012-08-17 Jakub Jelinek <jakub@redhat.com> |
9522 | ||
9523 | * c-tree.h (c_last_sizeof_arg): Declare. | |
9524 | * c-parser.c (struct c_tree_loc_pair): New type. | |
9525 | (c_parser_expr_list): Add sizeof_arg argument. Fill it in if | |
9526 | non-NULL. | |
9527 | (c_parser_attributes, c_parser_objc_keywordexpr): Adjust callers. | |
9528 | (c_parser_postfix_expression_after_primary): Likewise. Call | |
9529 | sizeof_pointer_memaccess_warning if needed. | |
9530 | (sizeof_ptr_memacc_comptypes): New function. | |
9531 | * c-typeck.c (c_last_sizeof_arg): New global variable. | |
9532 | (c_expr_sizeof_expr, c_expr_sizeof_type): Initialize it. | |
9533 | ||
0229aee9 UB |
9534 | 2012-07-24 Uros Bizjak <ubizjak@gmail.com> |
9535 | ||
9536 | * c-lang.h (lang_decl): Add variable_size GTY option. | |
9537 | ||
7ee2468b SB |
9538 | 2012-07-16 Steven Bosscher <steven@gcc.gnu.org> |
9539 | ||
9540 | * c-decl.c: Include dumpfile.h instead of tree-dump.h. | |
9541 | * Make-lang.in: Fix dependencies. | |
9542 | ||
d4a10d0a SB |
9543 | 2012-06-29 Steven Bosscher <steven@gcc.gnu.org> |
9544 | ||
9545 | * Make-lang.in: New file, rules migrated from gcc/Makefile.in | |
9546 | and add language Makefile hooks. | |
9547 | * config-lang.in: New file. | |
9548 | * c-config-lang.in: Moved from gcc/config-lang.in to here, and | |
9549 | add the required "normal" config-lang.in rules. | |
9550 | * c-lang.h: Moved from gcc/ to here. | |
9551 | * c-tree.h: Likewise. | |
9552 | * c-objc-common.c: Likewise. | |
9553 | * c-objc-common.h: Likewise. | |
9554 | * c-typeck.c: Likewise. | |
9555 | * c-convert.c: Likewise. | |
9556 | * c-lang.c: Likewise. | |
9557 | * c-aux-info.c: Likewise. | |
9558 | * c-errors.c: Likewise. | |
9559 | * gccspec.c: Likewise. | |
9560 | * c-decl.c: Likewise. Include gt-c-c-decl.h, not gt-c-decl.h. | |
9561 | * c-parser.c: Likewise. Include gt-c-c-parser.h, not gt-c-parser.h. | |
9562 | \f | |
68127a8e | 9563 | Copyright (C) 2012-2023 Free Software Foundation, Inc. |
d4a10d0a SB |
9564 | |
9565 | Copying and distribution of this file, with or without modification, | |
9566 | are permitted in any medium without royalty provided the copyright | |
9567 | notice and this notice are preserved. |