]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/fortran/ChangeLog
Daily bump.
[thirdparty/gcc.git] / gcc / fortran / ChangeLog
1 2023-07-11 Harald Anlauf <anlauf@gmx.de>
2
3 PR fortran/110288
4 * symbol.cc (gfc_copy_formal_args_intr): When deriving the formal
5 argument attributes from the actual ones for intrinsic procedure
6 calls, take special care of CHARACTER arguments that we do not
7 wrongly treat them formally as deferred-length.
8
9 2023-07-08 Steve Kargl <sgk@troutmask.apl.washington.edu>
10
11 PR fortran/99139
12 PR fortran/99368
13 * match.cc (gfc_match_namelist): Check for host associated or
14 defined types before applying default type.
15 (gfc_match_select_rank): Apply default type to selector of
16 unknown type if possible.
17 * resolve.cc (resolve_fl_variable): Do not apply local default
18 initialization to assumed rank entities.
19
20 2023-07-08 Harald Anlauf <anlauf@gmx.de>
21 Steven G. Kargl <kargl@gcc.gnu.org>
22
23 PR fortran/92178
24 * trans-expr.cc (gfc_conv_procedure_call): Check procedures for
25 allocatable dummy arguments with INTENT(OUT) and move deallocation
26 of actual arguments after evaluation of argument expressions before
27 the procedure is executed.
28
29 2023-07-08 Harald Anlauf <anlauf@gmx.de>
30
31 PR fortran/110585
32 * arith.cc (gfc_compare_expr): Handle equality comparison of constant
33 complex gfc_expr arguments.
34
35 2023-07-05 Robin Dapp <rdapp@ventanamicro.com>
36 Juzhe-Zhong <juzhe.zhong@rivai.ai>
37
38 * trans-types.cc (gfc_type_for_mode): Ditto.
39
40 2023-06-28 Harald Anlauf <anlauf@gmx.de>
41
42 PR fortran/110360
43 * trans-expr.cc (gfc_conv_procedure_call): For non-constant string
44 argument passed to CHARACTER(LEN=1),VALUE dummy, ensure proper
45 dereferencing and truncation of string to length 1.
46
47 2023-06-28 Paul Thomas <pault@gcc.gnu.org>
48
49 PR fortran/49213
50 * expr.cc (gfc_is_ptr_fcn): Remove reference to class_pointer.
51 * resolve.cc (resolve_assoc_var): Call gfc_is_ptr_fcn to allow
52 associate names with pointer function targets to be used in
53 variable definition context.
54 * trans-decl.cc (get_symbol_decl): Remove extraneous line.
55 * trans-expr.cc (alloc_scalar_allocatable_subcomponent): Obtain
56 size of intrinsic and character expressions.
57 (gfc_trans_subcomponent_assign): Expand assignment to class
58 components to include intrinsic and character expressions.
59
60 2023-06-24 Harald Anlauf <anlauf@gmx.de>
61
62 PR fortran/110360
63 * trans-expr.cc (gfc_conv_procedure_call): Truncate constant string
64 argument of length > 1 passed to scalar CHARACTER(1),VALUE dummy.
65
66 2023-06-23 Harald Anlauf <anlauf@gmx.de>
67
68 PR fortran/110360
69 * trans-expr.cc (gfc_conv_procedure_call): Pass actual argument
70 to scalar CHARACTER(1),VALUE dummy argument by value.
71
72 2023-06-21 Paul Thomas <pault@gcc.gnu.org>
73
74 PR fortran/87477
75 PR fortran/88688
76 PR fortran/94380
77 PR fortran/107900
78 PR fortran/110224
79 * decl.cc (char_len_param_value): Fix memory leak.
80 (resolve_block_construct): Remove unnecessary static decls.
81 * expr.cc (gfc_is_ptr_fcn): New function.
82 (gfc_check_vardef_context): Use it to permit pointer function
83 result selectors to be used for associate names in variable
84 definition context.
85 * gfortran.h: Prototype for gfc_is_ptr_fcn.
86 * match.cc (build_associate_name): New function.
87 (gfc_match_select_type): Use the new function to replace inline
88 version and to build a new associate name for the case where
89 the supplied associate name is already used for that purpose.
90 * resolve.cc (resolve_assoc_var): Call gfc_is_ptr_fcn to allow
91 associate names with pointer function targets to be used in
92 variable definition context.
93 * trans-decl.cc (gfc_get_symbol_decl): Unlimited polymorphic
94 variables need deferred initialisation of the vptr.
95 (gfc_trans_deferred_vars): Do the vptr initialisation.
96 * trans-stmt.cc (trans_associate_var): Ensure that a pointer
97 associate name points to the target of the selector and not
98 the selector itself.
99
100 2023-06-21 Paul Thomas <pault@gcc.gnu.org>
101
102 PR fortran/108961
103 * trans-expr.cc (gfc_conv_procedure_call): The hidden string
104 length must not be passed to a formal arg of type(cptr).
105
106 2023-06-20 Tobias Burnus <tobias@codesourcery.com>
107
108 * dump-parse-tree.cc (show_omp_namelist): Fix dump of the allocator
109 modifier of OMP_LIST_ALLOCATE.
110
111 2023-06-20 Tobias Burnus <tobias@codesourcery.com>
112
113 * match.cc (gfc_match_char): Match with '%S' a symbol
114 with host_assoc = 1.
115
116 2023-06-19 Tobias Burnus <tobias@codesourcery.com>
117
118 * intrinsic.texi (OpenMP Modules OMP_LIB and OMP_LIB_KINDS): Also
119 add references to the OpenMP 5.1 and 5.2 spec; add omp_initial_device
120 and omp_invalid_device named constants.
121
122 2023-06-13 Harald Anlauf <anlauf@gmx.de>
123 Mikael Morin <mikael@gcc.gnu.org>
124
125 PR fortran/86277
126 * trans-array.cc (gfc_trans_allocate_array_storage): When passing a
127 zero-sized array with fixed (= non-dynamic) size, allocate temporary
128 by the caller, not by the callee.
129
130 2023-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
131
132 * f95-lang.cc (gfc_init_builtin_functions): Add fmax() and
133 fmin() built-ins, and their variants.
134 * mathbuiltins.def: Add FMAX and FMIN built-ins.
135 * trans-intrinsic.cc (conv_intrinsic_ieee_minmax): New function.
136 (gfc_conv_ieee_arithmetic_function): Handle IEEE_MIN_NUM and
137 IEEE_MAX_NUM functions.
138
139 2023-06-09 Jakub Jelinek <jakub@redhat.com>
140
141 PR fortran/96024
142 * primary.cc (gfc_convert_to_structure_constructor): Only do
143 constant string ctor length verification and truncation/padding
144 if constant length has INTEGER type.
145
146 2023-06-08 Paul Thomas <pault@gcc.gnu.org>
147
148 PR fortran/87477
149 PR fortran/99350
150 PR fortran/107821
151 PR fortran/109451
152 * decl.cc (char_len_param_value): Simplify a copy of the expr
153 and replace the original if there is no error.
154 * gfortran.h : Remove the redundant field 'rankguessed' from
155 'gfc_association_list'.
156 * resolve.cc (resolve_assoc_var): Remove refs to 'rankguessed'.
157 (resolve_variable): Associate names with constant or structure
158 constructor targets cannot have array refs.
159 * trans-array.cc (gfc_conv_expr_descriptor): Guard expression
160 character length backend decl before using it. Suppress the
161 assignment if lhs equals rhs.
162 * trans-io.cc (gfc_trans_transfer): Scalarize transfer of
163 associate variables pointing to a variable. Add comment.
164 * trans-stmt.cc (trans_associate_var): Remove requirement that
165 the character length be deferred before assigning the value
166 returned by gfc_conv_expr_descriptor. Also, guard the backend
167 decl before testing with VAR_P.
168
169 2023-06-06 Kwok Cheung Yeung <kcy@codesourcery.com>
170 Tobias Burnus <tobias@codesourcery.com>
171
172 * dump-parse-tree.cc (show_omp_namelist): Display 'present' map
173 modifier.
174 (show_omp_clauses): Display 'present' motion modifier for 'to'
175 and 'from' clauses.
176 * gfortran.h (enum gfc_omp_map_op): Add entries with 'present'
177 modifiers.
178 (struct gfc_omp_namelist): Add 'present_modifer'.
179 * openmp.cc (gfc_match_motion_var_list): New, handles optional
180 'present' modifier for to/from clauses.
181 (gfc_match_omp_clauses): Call it for to/from clauses; parse 'present'
182 in defaultmap and map clauses.
183 (resolve_omp_clauses): Allow 'present' modifiers on 'target',
184 'target data', 'target enter' and 'target exit' directives.
185 * trans-openmp.cc (gfc_trans_omp_clauses): Apply 'present' modifiers
186 to tree node for 'map', 'to' and 'from' clauses. Apply 'present' for
187 defaultmap.
188
189 2023-06-02 Steve Kargl <kargl@gcc.gnu.org>
190
191 PR fortran/100607
192 * resolve.cc (resolve_select_rank): Remove duplicate error.
193 (resolve_fl_var_and_proc): Prevent NULL pointer dereference and
194 suppress error message for temporary.
195
196 2023-06-02 Paul Thomas <pault@gcc.gnu.org>
197
198 PR fortran/87477
199 * parse.cc (parse_associate): Replace the existing evaluation
200 of the target rank with calls to gfc_resolve_ref and
201 gfc_expression_rank. Identify untyped target function results
202 with structure constructors by finding the appropriate derived
203 type.
204 * resolve.cc (resolve_symbol): Allow associate variables to be
205 assumed shape.
206
207 2023-06-01 Harald Anlauf <anlauf@gmx.de>
208
209 PR fortran/88552
210 * decl.cc (gfc_match_kind_spec): Use error path on missing right
211 parenthesis.
212 (gfc_match_decl_type_spec): Use error return when an error occurred
213 during matching a KIND specifier.
214
215 2023-06-01 Tobias Burnus <tobias@codesourcery.com>
216
217 * parse.cc (decode_omp_directive): Accept all pure directives
218 inside a PURE procedures; handle 'error at(execution).
219
220 2023-05-26 Tobias Burnus <tobias@codesourcery.com>
221
222 * dump-parse-tree.cc (show_omp_namelist): Update allocator, fix
223 align dump.
224 (show_omp_node, show_code_node): Handle EXEC_OMP_ALLOCATE.
225 * gfortran.h (enum gfc_statement): Add ST_OMP_ALLOCATE and ..._EXEC.
226 (enum gfc_exec_op): Add EXEC_OMP_ALLOCATE.
227 (struct gfc_omp_namelist): Add 'allocator' to 'u2' union.
228 (struct gfc_namespace): Add omp_allocate.
229 (gfc_resolve_omp_allocate): New.
230 * match.cc (gfc_free_omp_namelist): Free 'u2.allocator'.
231 * match.h (gfc_match_omp_allocate, gfc_match_omp_allocators): New.
232 * openmp.cc (gfc_omp_directives): Uncomment allocate/allocators.
233 (gfc_match_omp_variable_list): Add bool arg for
234 rejecting listening common-block vars separately.
235 (gfc_match_omp_clauses): Update for u2.allocators.
236 (OMP_ALLOCATORS_CLAUSES, gfc_match_omp_allocate,
237 gfc_match_omp_allocators, is_predefined_allocator,
238 gfc_resolve_omp_allocate): New.
239 (resolve_omp_clauses): Update 'allocate' clause checks.
240 (omp_code_to_statement, gfc_resolve_omp_directive): Handle
241 OMP ALLOCATE/ALLOCATORS.
242 * parse.cc (in_exec_part): New global var.
243 (check_omp_allocate_stmt, parse_openmp_allocate_block): New.
244 (decode_omp_directive, case_exec_markers, case_omp_decl,
245 gfc_ascii_statement, parse_omp_structured_block): Handle
246 OMP allocate/allocators.
247 (verify_st_order, parse_executable): Set in_exec_part.
248 * resolve.cc (gfc_resolve_blocks, resolve_codes): Handle
249 allocate/allocators.
250 * st.cc (gfc_free_statement): Likewise.
251 * trans.cc (trans_code): Likewise.
252 * trans-openmp.cc (gfc_trans_omp_directive): Likewise.
253 (gfc_trans_omp_clauses, gfc_split_omp_clauses): Update for
254 u2.allocator, fix for u.align.
255
256 2023-05-24 Harald Anlauf <anlauf@gmx.de>
257
258 PR fortran/104350
259 * simplify.cc (simplify_size): Reject DIM argument of intrinsic SIZE
260 with error when out of valid range.
261
262 2023-05-24 Harald Anlauf <anlauf@gmx.de>
263
264 PR fortran/103794
265 * check.cc (gfc_check_reshape): Expand constant arguments SHAPE and
266 ORDER before checking.
267 * gfortran.h (gfc_is_constant_array_expr): Add prototype.
268 * iresolve.cc (gfc_resolve_reshape): Expand constant argument SHAPE.
269 * simplify.cc (is_constant_array_expr): If array is determined to be
270 constant, expand small array constructors if needed.
271 (gfc_is_constant_array_expr): Wrapper for is_constant_array_expr.
272 (gfc_simplify_reshape): Fix check for insufficient elements in SOURCE
273 when no padding specified.
274
275 2023-05-23 Paul Thomas <pault@gcc.gnu.org>
276
277 PR fortran/103716
278 * resolve.cc (gfc_resolve_ref): Conversion of array_ref into an
279 element should be done for all characters without a len expr,
280 not just deferred lens, and for integer expressions.
281 * trans-expr.cc (conv_inquiry): For len and kind inquiry refs,
282 set the se string_length to NULL_TREE.
283
284 2023-05-23 Paul Thomas <pault@gcc.gnu.org>
285 Steven G. Kargl <kargl@gcc.gnu.org>
286
287 PR fortran/97122
288 * decl.cc (variable_decl): Clean up white space issues.
289 (gfc_match_final_decl): Declaration of finalizable derived type
290 is allowed in a submodule.
291
292 2023-05-19 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
293
294 * expr.cc (gfc_get_corank): Use CLASS_DATA from gfortran.h.
295 * resolve.cc (resolve_component): Same.
296 (resolve_fl_derived0): Same.
297 * simplify.cc (gfc_simplify_extends_type_of): Same.
298 (simplify_cobound): Same.
299
300 2023-05-18 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
301
302 * trans-array.cc (is_pointer_array): Use _P() defines from tree.h.
303 (gfc_conv_scalarized_array_ref): Ditto.
304 (gfc_conv_array_ref): Ditto.
305 * trans-decl.cc (gfc_finish_decl): Ditto.
306 (gfc_get_symbol_decl): Ditto.
307 * trans-expr.cc (gfc_trans_pointer_assignment): Ditto.
308 (gfc_trans_arrayfunc_assign): Ditto.
309 (gfc_trans_assignment_1): Ditto.
310 * trans-intrinsic.cc (gfc_conv_intrinsic_minmax): Ditto.
311 (conv_intrinsic_ieee_value): Ditto.
312 * trans-io.cc (gfc_convert_array_to_string): Ditto.
313 * trans-openmp.cc (gfc_omp_is_optional_argument): Ditto.
314 (gfc_trans_omp_clauses): Ditto.
315 * trans-stmt.cc (gfc_conv_label_variable): Ditto.
316 * trans.cc (gfc_build_addr_expr): Ditto.
317 (get_array_span): Ditto.
318
319 2023-05-18 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
320
321 PR fortran/78798
322 * array.cc (compare_bounds): Use narrower return type.
323 (gfc_compare_array_spec): Likewise.
324 (is_constant_element): Likewise.
325 (gfc_constant_ac): Likewise.
326 * check.cc (dim_rank_check): Likewise.
327 * cpp.cc (gfc_cpp_init_options): Likewise.
328 (dump_macro): Likewise.
329 * cpp.h (gfc_cpp_handle_option): Likewise.
330 * dependency.cc (gfc_ref_needs_temporary_p): Likewise.
331 (gfc_check_argument_dependency): Likewise.
332 (gfc_check_fncall_dependency): Likewise.
333 (ref_same_as_full_array): Likewise.
334 * dependency.h (gfc_check_fncall_dependency): Likewise.
335 (gfc_dep_resolver): Likewise.
336 (gfc_are_equivalenced_arrays): Likewise.
337 * expr.cc (gfc_copy_ref): Likewise.
338 (gfc_kind_max): Likewise.
339 (numeric_type): Likewise.
340 * gfortran.h (gfc_at_end): Likewise.
341 (gfc_at_eof): Likewise.
342 (gfc_at_bol): Likewise.
343 (gfc_at_eol): Likewise.
344 (gfc_define_undef_line): Likewise.
345 (gfc_wide_is_printable): Likewise.
346 (gfc_wide_is_digit): Likewise.
347 (gfc_wide_fits_in_byte): Likewise.
348 (gfc_find_sym_tree): Likewise.
349 (gfc_generic_intrinsic): Likewise.
350 (gfc_specific_intrinsic): Likewise.
351 (gfc_intrinsic_actual_ok): Likewise.
352 (gfc_has_vector_index): Likewise.
353 (gfc_numeric_ts): Likewise.
354 (gfc_impure_variable): Likewise.
355 (gfc_pure): Likewise.
356 (gfc_implicit_pure): Likewise.
357 (gfc_elemental): Likewise.
358 (gfc_pure_function): Likewise.
359 (gfc_implicit_pure_function): Likewise.
360 (gfc_compare_array_spec): Likewise.
361 (gfc_constant_ac): Likewise.
362 (gfc_expanded_ac): Likewise.
363 (gfc_check_digit): Likewise.
364 * intrinsic.cc (gfc_find_subroutine): Likewise.
365 (gfc_generic_intrinsic): Likewise.
366 (gfc_specific_intrinsic): Likewise.
367 * io.cc (compare_to_allowed_values): Likewise. And remove
368 unneeded forward declaration.
369 * parse.cc: Likewise.
370 * parse.h (gfc_check_do_variable): Likewise.
371 * primary.cc (gfc_check_digit): Likewise.
372 * resolve.cc (resolve_structure_cons): Likewise.
373 (pure_stmt_function): Likewise.
374 (gfc_pure_function): Likewise.
375 (impure_stmt_fcn): Likewise.
376 (resolve_forall_iterators): Likewise.
377 (resolve_data): Likewise.
378 (gfc_impure_variable): Likewise.
379 (gfc_pure): Likewise.
380 (gfc_unset_implicit_pure): Likewise.
381 * scanner.cc (wide_is_ascii): Likewise.
382 (gfc_wide_toupper): Likewise.
383 (gfc_open_included_file): Likewise.
384 (gfc_at_end): Likewise.
385 (gfc_at_eof): Likewise.
386 (gfc_at_bol): Likewise.
387 (skip_comment_line): Likewise.
388 (gfc_gobble_whitespace): Likewise.
389 * symbol.cc (gfc_find_symtree_in_proc): Likewise.
390 * trans-array.cc: Likewise.
391 * trans-decl.cc (gfc_set_decl_assembler_name): Likewise.
392 * trans-types.cc (gfc_get_element_type): Likewise.
393 (gfc_add_field_to_struct): Likewise.
394 * trans-types.h (gfc_copy_dt_decls_ifequal): Likewise.
395 (gfc_return_by_reference): Likewise.
396 (gfc_is_nodesc_array): Likewise.
397 * trans.h (gfc_can_put_var_on_stack): Likewise.
398
399 2023-05-17 Harald Anlauf <anlauf@gmx.de>
400
401 PR fortran/95374
402 PR fortran/104352
403 * decl.cc (add_init_expr_to_sym): Set shape of initializer also for
404 zero-sized arrays, so that bounds violations can be detected later.
405
406 2023-05-17 Tobias Burnus <tobias@codesourcery.com>
407
408 * trans-decl.cc (gfc_get_symbol_decl): Add attributes
409 such as 'declare target' also to hidden artificial
410 variable for deferred-length character variables.
411 * trans-openmp.cc (gfc_trans_omp_array_section,
412 gfc_trans_omp_clauses, gfc_trans_omp_target_exit_data):
413 Improve mapping of array descriptors and deferred-length
414 string variables.
415
416 2023-05-16 Paul Thomas <pault@gcc.gnu.org>
417
418 PR fortran/105152
419 PR fortran/100193
420 PR fortran/87496
421 PR fortran/103389
422 PR fortran/104429
423 PR fortran/82774
424 * interface.cc (gfc_compare_actual_formal): Emit an error if an
425 unlimited polymorphic actual is not matched either to an
426 unlimited or assumed type formal argument.
427 * resolve.cc (resolve_ordinary_assign): Emit an error if the
428 var expression of an ordinary assignment is a proc pointer
429 component.
430 * trans-array.cc (gfc_walk_array_ref): Provide assumed shape
431 arrays coming from interface mapping with a viable arrayspec.
432 * trans-expr.cc (gfc_conv_intrinsic_to_class): Tidy up flagging
433 of unlimited polymorphic 'class_ts'.
434 (gfc_conv_gfc_desc_to_cfi_desc): Assumed type is unlimited
435 polymorphic and should accept any actual type.
436 (gfc_conv_procedure_call): Replace dreadful kludge with a call
437 to gfc_finalize_tree_expr. Avoid dereferencing a void pointer
438 by giving it the pointer type of the actual argument.
439 (alloc_scalar_allocatable_subcomponent): Shorten the function
440 name and replace the symbol argument with the se string length.
441 If a deferred length character length is either not present or
442 is not a variable, give the typespec a variable and assign the
443 string length to that. Use gfc_deferred_strlen to find the
444 hidden string length component.
445 (gfc_trans_subcomponent_assign): Convert the expression before
446 the call to alloc_scalar_allocatable_subcomponent so that a
447 good string length is provided.
448 (gfc_trans_structure_assign): Remove the unneeded derived type
449 symbol from calls to gfc_trans_subcomponent_assign.
450
451 2023-05-15 Harald Anlauf <anlauf@gmx.de>
452
453 PR fortran/109846
454 * expr.cc (gfc_check_vardef_context): Check appropriate pointer
455 attribute for CLASS vs. non-CLASS function result in variable
456 definition context.
457
458 2023-05-11 Xi Ruoyao <xry111@xry111.site>
459
460 * Make-lang.in: Use grep instead of fgrep.
461
462 2023-05-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
463
464 * dump-parse-tree.cc (gfc_debug_expr): Remove forward declaration.
465 (debug): Add DEBUG_FUNCTION.
466 (show_code_node): Remove erroneous whitespace.
467
468 2023-05-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
469
470 PR fortran/109624
471 * dump-parse-tree.cc (debug): New function for gfc_namespace.
472 (gfc_debug_code): Delete forward declaration.
473 (show_attr): Make sure to print balanced braces.
474
475 2023-05-08 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
476
477 * resolve.cc (resolve_select_type): Fix coding style.
478
479 2023-05-08 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
480
481 * resolve.cc (resolve_select_type): Call free() unconditionally.
482
483 2023-05-08 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
484
485 PR fortran/68800
486 * expr.cc (find_array_section): Fix mpz memory leak.
487 * simplify.cc (gfc_simplify_reshape): Fix mpz memory leaks in
488 error paths.
489
490 2023-05-05 Harald Anlauf <anlauf@gmx.de>
491
492 PR fortran/109641
493 * arith.cc (eval_intrinsic): Check conformability of ranks of operands
494 for intrinsic binary operators before performing type conversions.
495 * gfortran.h (gfc_op_rank_conformable): Add prototype.
496 * resolve.cc (resolve_operator): Check conformability of ranks of
497 operands for intrinsic binary operators before performing type
498 conversions.
499 (gfc_op_rank_conformable): New helper function to compare ranks of
500 operands of binary operator.
501
502 2023-05-04 Julian Brown <julian@codesourcery.com>
503
504 PR fortran/109622
505 * openmp.cc (resolve_omp_clauses): Add diagnostic for
506 non-pointer/non-allocatable attach/detach.
507 * trans-openmp.cc (gfc_trans_omp_clauses): Remove dereference for
508 pointer-to-scalar derived type component attach/detach. Fix
509 attach/detach handling for descriptors.
510
511 2023-04-28 Julian Brown <julian@codesourcery.com>
512
513 PR fortran/109622
514 * trans-openmp.cc (gfc_trans_omp_clauses): Attach/detach clause fixes.
515
516 2023-04-28 Tobias Burnus <tobias@codesourcery.com>
517
518 * gfortran.texi: Fix typos.
519 * decl.cc: Fix typos in comments and in a variable name.
520 * arith.cc: Fix comment typos.
521 * check.cc: Likewise.
522 * class.cc: Likewise.
523 * dependency.cc: Likewise.
524 * expr.cc: Likewise.
525 * frontend-passes.cc: Likewise.
526 * gfortran.h: Likewise.
527 * intrinsic.cc: Likewise.
528 * iresolve.cc: Likewise.
529 * match.cc: Likewise.
530 * module.cc: Likewise.
531 * primary.cc: Likewise.
532 * resolve.cc: Likewise.
533 * simplify.cc: Likewise.
534 * trans-array.cc: Likewise.
535 * trans-decl.cc: Likewise.
536 * trans-expr.cc: Likewise.
537 * trans-intrinsic.cc: Likewise.
538 * trans-openmp.cc: Likewise.
539 * trans-stmt.cc: Likewise.
540
541 2023-04-25 Tobias Burnus <tobias@codesourcery.com>
542
543 * openmp.cc (gfc_resolve_omp_do_blocks): Handle zero
544 or more than one exec statements before/after 'omp scan'.
545 * trans-openmp.cc (gfc_trans_omp_do): Likewise.
546
547 2023-04-22 Harald Anlauf <anlauf@gmx.de>
548 Steven G. Kargl <kargl@gcc.gnu.org>
549
550 PR fortran/109500
551 * interface.cc (gfc_compare_actual_formal): Reject allocatable
552 functions being used as actual argument for allocable dummy.
553
554 2023-04-14 Harald Anlauf <anlauf@gmx.de>
555
556 PR fortran/109511
557 * simplify.cc (gfc_simplify_set_exponent): Fix implementation of
558 compile-time simplification of intrinsic SET_EXPONENT for argument
559 X < 1 and for I < 0.
560
561 2023-04-14 Paul Thomas <pault@gcc.gnu.org>
562
563 PR fortran/104272
564 * gfortran.h : Add expr3_not_explicit bit field to gfc_code.
565 * resolve.cc (resolve_allocate_expr): Set bit field when the
566 default initializer is applied to expr3.
567 * trans-stmt.cc (gfc_trans_allocate): If expr3_not_explicit is
568 set, do not deallocate expr3.
569
570 2023-04-13 Harald Anlauf <anlauf@gmx.de>
571
572 PR fortran/109492
573 * trans-expr.cc (gfc_conv_power_op): Use absu_hwi and
574 unsigned HOST_WIDE_INT for portability.
575
576 2023-04-12 Harald Anlauf <anlauf@gmx.de>
577
578 PR fortran/104312
579 * resolve.cc (resolve_entries): Handle functions with ENTRY and
580 ALLOCATABLE results.
581 * trans-expr.cc (gfc_conv_procedure_call): Functions with a result
582 with the POINTER or ALLOCATABLE attribute shall not get any special
583 treatment with -ff2c, as they cannot be written in Fortran 77.
584 * trans-types.cc (gfc_return_by_reference): Likewise.
585 (gfc_get_function_type): Likewise.
586
587 2023-04-12 Harald Anlauf <anlauf@gmx.de>
588
589 PR fortran/61615
590 PR fortran/99982
591 * interface.cc (compare_parameter): Enable type and rank checks for
592 arguments of derived type from the intrinsic module ISO_C_BINDING.
593
594 2023-04-08 Paul Thomas <pault@gcc.gnu.org>
595
596 PR fortran/87477
597 * iresolve.cc (gfc_resolve_adjustl, gfc_resolve_adjustr): if
598 string length is deferred use the string typespec for result.
599 * resolve.cc (resolve_assoc_var): Handle parentheses around the
600 target expression.
601 (resolve_block_construct): Remove unnecessary static decls.
602 * trans-array.cc (gfc_conv_expr_descriptor): Guard string len
603 expression in condition. Improve handling of string length and
604 span, especially for substrings of the descriptor.
605 (duplicate_allocatable): Make element type more explicit with
606 'eltype'.
607 * trans-decl.cc (gfc_get_symbol_decl): Emit a fatal error with
608 appropriate message instead of ICE if symbol type is unknown.
609 (gfc_generate_function_code): Set current locus to proc_sym
610 declared_at.
611 * trans-expr.cc (gfc_get_expr_charlen): Retain last charlen in
612 'previous' and use if end expression in substring reference is
613 null.
614 (gfc_conv_string_length): Use gfc_conv_expr_descriptor if
615 'expr_flat' is an array. Add post block to catch deallocation
616 of temporaries.
617 (gfc_conv_procedure_call): Assign the parmse string length to
618 the expression string length, if it is deferred.
619 (gfc_trans_alloc_subarray_assign): If this is a deferred string
620 length component, store the string length in the hidden comp.
621 Update the typespec length accordingly. Generate a new type
622 spec for the call to gfc_duplicate-allocatable in this case.
623 * trans-io.cc (gfc_trans_transfer): Scalarize transfer of
624 deferred character array components.
625
626 2023-04-04 Harald Anlauf <anlauf@gmx.de>
627
628 PR fortran/104349
629 * expr.cc (check_restricted): Adjust check for valid variables in
630 restricted expressions: make no exception for module variables.
631
632 2023-04-01 Thomas Koenig <tkoenig@gcc.gnu.org>
633
634 * dump-parse-tree.cc (get_c_type_name): Fix "long_long"
635 type name to be "long long".
636
637 2023-03-30 Andrew Pinski <apinski@marvell.com>
638
639 * dump-parse-tree.cc (get_c_type_name): Fix "long_long"
640 type name to be "long long". Add a comment on why adding
641 2 to the name too.
642
643 2023-03-28 Jakub Jelinek <jakub@redhat.com>
644
645 PR fortran/109314
646 * openmp.cc (gfc_omp_absent_contains_clause): Fix typo in diagnostics
647 - composit -> composite.
648
649 2023-03-25 Harald Anlauf <anlauf@gmx.de>
650
651 PR fortran/104321
652 * trans-decl.cc (gfc_conv_cfi_to_gfc): Remove dead code.
653
654 2023-03-24 Harald Anlauf <anlauf@gmx.de>
655
656 * expr.cc (free_expr0): Free also BOZ strings as part of an expression.
657
658 2023-03-24 Haochen Gui <guihaoc@gcc.gnu.org>
659 Tobias Burnus <tobias@codesourcery.com>
660
661 PR target/103628
662 * target-memory.cc (gfc_interpret_float): Return FAIL when
663 native_interpret_expr gets a NULL tree.
664 * arith.cc (gfc_hollerith2real): Return NULL when
665 gfc_interpret_float fails.
666 * error.cc (gfc_buffered_p): Define.
667 * gfortran.h (gfc_buffered_p): Declare.
668 * intrinsic.cc: Add diagnostic.h to include list.
669 (do_simplify): Save errorcount and check it at finish. Report a
670 "Cannot simplify expression" error on a bad result if error count
671 doesn't change and no other errors buffered.
672
673 2023-03-22 Harald Anlauf <anlauf@gmx.de>
674 Steven G. Kargl <kargl@gcc.gnu.org>
675
676 PR fortran/104572
677 * resolve.cc (gfc_resolve_finalizers): Argument of a FINAL subroutine
678 cannot be an alternate return.
679
680 2023-03-21 Harald Anlauf <anlauf@gmx.de>
681
682 PR fortran/99036
683 * decl.cc (gfc_match_modproc): Reject MODULE PROCEDURE if not in a
684 generic module interface.
685
686 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
687
688 * invoke.texi: Remove usages of @gol.
689 * intrinsic.texi: Ditto.
690
691 2023-03-21 Paul Thomas <pault@gcc.gnu.org>
692
693 PR fortran/109206
694 * trans-array.cc (gfc_trans_array_constructor_value): Correct
695 incorrect setting of typespec.
696
697 2023-03-21 Paul Thomas <pault@gcc.gnu.org>
698
699 PR fortran/109209
700 * resolve.cc (generate_component_assignments): Restore the
701 exclusion of allocatable components from the loop.
702
703 2023-03-20 Harald Anlauf <anlauf@gmx.de>
704
705 PR fortran/109216
706 * invoke.texi: Correct documentation of how underscores are appended
707 to external names.
708
709 2023-03-20 Harald Anlauf <anlauf@gmx.de>
710
711 PR fortran/109186
712 * simplify.cc (gfc_simplify_nearest): Fix off-by-one error in setting
713 up real kind-specific maximum exponent for mpfr.
714
715 2023-03-20 Paul Thomas <pault@gcc.gnu.org>
716
717 PR fortran/87127
718 * resolve.cc (check_host_association): If an external function
719 is typed but not declared explicitly to be external, change the
720 old symbol from a variable to an external function.
721
722 2023-03-19 Harald Anlauf <anlauf@gmx.de>
723
724 PR fortran/85877
725 * resolve.cc (resolve_fl_procedure): Check for an explicit interface
726 of procedures with the BIND(C) attribute (F2018:15.4.2.2).
727
728 2023-03-19 Thomas Koenig <tkoenig@gcc.gnu.org>
729
730 * gfortran.texi: Mention behavior on overflow.
731
732 2023-03-18 Paul Thomas <pault@gcc.gnu.org>
733
734 PR fortran/103854
735 PR fortran/96122
736 PR fortran/37336
737 * class.cc (finalize_component): Include the missing arguments
738 in the call to the component's finalizer wrapper.
739 (has_finalizer_component): Do not return true for procedure
740 pointer components.
741 (finalizer_insert_packed_call): Remove the redundant argument
742 in the call to the final subroutine.
743 (generate_finalization_wrapper): Add support for assumed rank
744 finalizers.
745 (gfc_may_be_finalized): New helper function.
746 * dump-parse-tree.cc (write_proc): Whitespace.
747 * gfortran.h : Add prototype for gfc_may_be_finalized.
748 * resolve.cc (resolve_function): Correct derived types that
749 have an incomplete namespace.
750 (resolve_where, gfc_resolve_where_code_in_forall,
751 gfc_resolve_forall_body, gfc_resolve_code): Check that the op
752 code is still EXEC_ASSIGN. If it is set lhs to must finalize.
753 (is_finalizable_type): New function.
754 (generate_component_assignments): Set must_finalize if needed.
755 (gfc_resolve_finalizers): Error if assumed rank finalizer is
756 not the only one. Warning on lack of scalar finalizer modified
757 to account for assumed rank finalizers.
758 (generate_final_call): New function.
759 (generate_component_assignments): Enclose the outermost call in
760 a block to capture automatic deallocation and final calls.
761 Set must_finalize as required to satisfy the standards. Use an
762 explicit pointer assignment for pointer components to capture
763 finalization of the target. Likewise use explicit assignment
764 for allocatable components. Do not use the temporary copy of
765 the lhs in defined assignment if the component is allocatable.
766 Put the temporary in the same namespace as the lhs symbol if
767 the component may be finalized. Remove the leading assignment
768 from the expansion of assignment of components that have their
769 own defined assignment components. Suppress finalization of
770 assignment of temporary components to the lhs. Make an explicit
771 final call for the rhs function temporary if it exists.
772 (gfc_resolve_code): Set must_finalize for assignments with an
773 array constructor on the rhs.
774 (gfc_resolve_finalizers): Ensure that an assumed rank finalizer
775 is the only finalizer for that type and correct the surprising
776 warning for the lack of a scalar finalizer.
777 (check_defined_assignments): Handle allocatable components.
778 (resolve_fl_derived): Set referenced the vtab for use
779 associated symbols.
780 (resolve_symbol): Set referenced an unreferenced symbol that
781 will be finalized.
782 * trans-array.cc (gfc_trans_array_constructor_value): Add code
783 to finalize the constructor result. Warn that this feature was
784 removed in F2018 and that it is suppressed by -std=2018.
785 (trans_array_constructor): Add finalblock, pass to previous
786 and apply to loop->post if filled.
787 (gfc_add_loop_ss_code): Add se finalblock to outer loop post.
788 (gfc_trans_array_cobounds, gfc_trans_array_bounds): Add any
789 generated finalization code to the main block.
790 (structure_alloc_comps): Add boolean argument to suppress
791 finalization and use it for calls from
792 gfc_deallocate_alloc_comp_no_caf. Otherwise it defaults to
793 false.
794 (gfc_copy_alloc_comp_no_fini): New wrapper for
795 structure_alloc_comps.
796 (gfc_alloc_allocatable_for_assignment): Suppress finalization
797 by setting new arg in call to gfc_deallocate_alloc_comp_no_caf.
798 (gfc_trans_deferred_array): Use gfc_may_be_finalized and do not
799 deallocate the components of entities with a leading '_' in the
800 name that are also marked as artificial.
801 * trans-array.h : Add the new boolean argument to the prototype
802 of gfc_deallocate_alloc_comp_no_caf with a default of false.
803 Add prototype for gfc_copy_alloc_comp_no_fini.
804 * trans-decl.cc(init_intent_out_dt): Tidy up the code.
805 * trans-expr.cc (gfc_init_se): Initialize finalblock.
806 (gfc_conv_procedure_call): Use gfc_finalize_tree_expr to
807 finalize function results. Replace in-line block for class
808 results with call to new function.
809 (gfc_conv_expr): Finalize structure constructors for F2003 and
810 F2008. Warn that this feature was deleted in F2018 and, unlike
811 array constructors, is not default. Add array constructor
812 finalblock to the post block.
813 (gfc_trans_scalar_assign): Suppress finalization by setting new
814 argument in call to gfc_deallocate_alloc_comp_no_caf. Add the
815 finalization blocks to the main block.
816 (gfc_trans_arrayfunc_assign): Use gfc_assignment_finalizer_call
817 and ensure that finalization occurs after the evaluation of the
818 rhs but using the initial value for the lhs. Finalize rhs
819 function results using gfc_finalize_tree_expr.
820 (trans_class_assignment, gfc_trans_assignment_1): As previous
821 function, taking care to order evaluation, assignment and
822 finalization correctly.
823 * trans-io.cc (gfc_trans_transfer): Add the final block.
824 * trans-stmt.cc (gfc_trans_call, gfc_trans_allocate): likewise.
825 (trans_associate_var): Nullify derived allocatable components
826 and finalize function targets with defined assignment
827 components on leaving the block scope.
828 (trans_allocate): Finalize source expressions, if required,
829 and set init_expr artificial temporarily to suppress the
830 finalization in gfc_trans_assignment.
831 * trans.cc (gfc_add_finalizer_call): Do not finalize the
832 temporaries generated in type assignment with defined
833 assignment components.
834 (gfc_assignment_finalizer_call): New function.
835 (gfc_finalize_tree_expr): New function.
836 * trans.h: Add finalblock to gfc_se. Add the prototypes for
837 gfc_finalize_tree_expr and gfc_assignment_finalizer_call.
838
839 2023-03-15 Harald Anlauf <anlauf@gmx.de>
840 Tobias Burnus <tobias@codesourcery.com>
841
842 PR fortran/58331
843 * interface.cc (compare_parameter): Adjust check of array dummy
844 arguments to handle the case of CLASS variables.
845
846 2023-03-11 Harald Anlauf <anlauf@gmx.de>
847
848 PR fortran/106945
849 * trans-expr.cc (gfc_copy_class_to_class): Convert element counts in
850 bounds check to common type for comparison.
851
852 2023-03-10 Harald Anlauf <anlauf@gmx.de>
853
854 PR fortran/104332
855 * resolve.cc (resolve_symbol): Avoid NULL pointer dereference while
856 checking a symbol with the BIND(C) attribute.
857
858 2023-03-05 Harald Anlauf <anlauf@gmx.de>
859 Tobias Burnus <tobias@codesourcery.com>
860
861 PR fortran/106856
862 * class.cc (gfc_build_class_symbol): Handle update of attributes of
863 existing class container.
864 (gfc_find_derived_vtab): Fix several memory leaks.
865 (find_intrinsic_vtab): Ditto.
866 * decl.cc (attr_decl1): Manage update of symbol attributes from
867 CLASS attributes.
868 * primary.cc (gfc_variable_attr): OPTIONAL shall not be taken or
869 updated from the class container.
870 * symbol.cc (free_old_symbol): Adjust management of symbol versions
871 to not prematurely free array specs while working on the declation
872 of CLASS variables.
873
874 2023-03-01 Tobias Burnus <tobias@codesourcery.com>
875
876 PR middle-end/108546
877 * trans-openmp.cc (gfc_trans_omp_clauses): Fix mapping of
878 type(C_ptr) variables.
879
880 2023-02-27 Harald Anlauf <anlauf@gmx.de>
881
882 PR fortran/108937
883 * trans-intrinsic.cc (gfc_conv_intrinsic_ibits): Handle corner case
884 LEN argument of IBITS equal to BITSIZE(I).
885
886 2023-02-25 Mikael Morin <mikael@gcc.gnu.org>
887
888 PR fortran/108923
889 * intrinsic.cc (get_intrinsic_dummy_arg,
890 set_intrinsic_dummy_arg): Rename the former to the latter.
891 Remove the return value, add a reference to the lhs as argument,
892 and do the pointer assignment inside the function. Don't do
893 it if the pointer is already non-NULL.
894 (sort_actual): Update caller.
895
896 2023-02-25 Harald Anlauf <anlauf@gmx.de>
897
898 * arith.cc (gfc_real2int): Clear mpfr variable after use.
899
900 2023-02-25 Tobias Burnus <tobias@codesourcery.com>
901
902 PR fortran/108621
903 * trans-expr.cc (gfc_conv_gfc_desc_to_cfi_desc): Skip setting of
904 bounds of CFI desc for 'pointer,intent(out)'.
905
906 2023-02-24 Rimvydas Jasinskas <rimvydas.jas@gmail.com>
907
908 * trans-decl.cc (gfc_finish_var_decl): Apply attribute.
909 (generate_local_decl): Add diagnostic for dummy and local variables.
910
911 2023-02-24 Mikael Morin <mikael@gcc.gnu.org>
912
913 PR fortran/108923
914 * expr.cc (gfc_free_actual_arglist): Free associated_dummy
915 memory.
916 (gfc_copy_actual_arglist): Make a copy of the associated_dummy
917 field if it is set in the original element.
918
919 2023-02-24 Harald Anlauf <anlauf@gmx.de>
920
921 PR fortran/108924
922 * frontend-passes.cc (do_subscript): Clear used gmp variable.
923
924 2023-02-23 Arsen Arsenović <arsen@aarsen.me>
925
926 * invoke.texi: Reorder index entries around @items.
927
928 2023-02-23 Arsen Arsenović <arsen@aarsen.me>
929
930 * invoke.texi: Reorder @opindex commands to precede @items they
931 relate to.
932
933 2023-02-22 Harald Anlauf <anlauf@gmx.de>
934
935 PR fortran/96024
936 * resolve.cc (resolve_component): The type of a CHARACTER length
937 expression must be INTEGER.
938
939 2023-02-21 Harald Anlauf <anlauf@gmx.de>
940
941 PR fortran/96025
942 * parse.cc (check_function_result_typed): Improve type check of
943 specification expression for character length and return status.
944 (parse_spec): Use status from above.
945 * resolve.cc (resolve_fntype): Prevent use of invalid specification
946 expression for character length.
947
948 2023-02-16 Patrick Palka <ppalka@redhat.com>
949
950 * gfortran.h: Mechanically drop static from static inline
951 functions via s/^static inline/inline/g.
952
953 2023-02-15 Steve Kargl <kargl@gcc.gnu.org>
954
955 PR fortran/103608
956 * frontend-passes.cc (do_intent): Catch NULL pointer dereference on
957 reference to invalid formal argument.
958
959 2023-02-15 Steve Kargl <kargl@gcc.gnu.org>
960
961 PR fortran/104554
962 * resolve.cc (check_assumed_size_reference): Avoid NULL pointer
963 dereference.
964
965 2023-02-15 Tobias Burnus <tobias@codesourcery.com>
966
967 PR fortran/108512
968 * openmp.cc (gfc_resolve_omp_parallel_blocks): Handle combined 'loop'
969 directives.
970 (gfc_resolve_do_iterator): Set a source location for added
971 'private'-clause arguments.
972 * resolve.cc (gfc_resolve_code): Call gfc_resolve_omp_do_blocks
973 also for EXEC_OMP_LOOP and gfc_resolve_omp_parallel_blocks for
974 combined directives with loop + '{masked,master} taskloop (simd)'.
975
976 2023-02-13 Harald Anlauf <anlauf@gmx.de>
977
978 PR fortran/103475
979 * primary.cc (gfc_expr_attr): Avoid NULL pointer dereference for
980 invalid use of CLASS variable.
981
982 2023-02-13 Rimvydas Jasinskas <rimvydas.jas@gmail.com>
983
984 * decl.cc: Add EXT_ATTR_NOINLINE, EXT_ATTR_NORETURN, EXT_ATTR_WEAK.
985 * gfortran.h (ext_attr_id_t): Ditto.
986 * gfortran.texi (GCC$ ATTRIBUTES): Document them.
987 * trans-decl.cc (build_function_decl): Apply them.
988
989 2023-02-09 Harald Anlauf <anlauf@gmx.de>
990 Steven G. Kargl <kargl@gcc.gnu.org>
991
992 PR fortran/69636
993 PR fortran/103779
994 * intrinsic.cc (gfc_convert_chartype): Recover on invalid character
995 kind in conversion instead of generating an internal error.
996
997 2023-02-09 Tobias Burnus <tobias@codesourcery.com>
998
999 PR fortran/107424
1000 * trans-openmp.cc (struct dovar_init_d): Add 'sym' and
1001 'non_unit_incr' members.
1002 (gfc_nonrect_loop_expr): New.
1003 (gfc_trans_omp_do): Call it; use normal loop bounds
1004 for unit stride - and only create local loop var.
1005
1006 2023-02-09 Tobias Burnus <tobias@codesourcery.com>
1007
1008 * parse.cc (decode_omp_directive): Really ignore 'assumes' with
1009 -fopenmp-simd.
1010
1011 2023-02-08 Steve Kargl <kargl@gcc.gnu.org>
1012
1013 PR fortran/103259
1014 * resolve.cc (resolve_common_vars): Avoid NULL pointer dereference
1015 when a symbol's location is not set.
1016
1017 2023-02-07 Harald Anlauf <anlauf@gmx.de>
1018
1019 PR fortran/95107
1020 * trans-decl.cc (gfc_finish_var_decl): With -fno-automatic, do not
1021 make ASSOCIATE variables TREE_STATIC.
1022
1023 2023-02-05 Harald Anlauf <anlauf@gmx.de>
1024
1025 PR fortran/108592
1026 * arith.cc (gfc_arith_divide): Emit integer division truncation
1027 warnings using gfc_warning instead of gfc_warning_now to prevent
1028 redundant messages.
1029
1030 2023-02-03 Jakub Jelinek <jakub@redhat.com>
1031
1032 PR fortran/108451
1033 * trans-decl.cc (gfc_trans_use_stmts): Call clear_slot before
1034 doing continue.
1035
1036 2023-02-01 Harald Anlauf <anlauf@gmx.de>
1037
1038 PR fortran/108609
1039 * expr.cc (find_array_section): Add check to prevent interpreting an
1040 mpz non-integer constant as an integer.
1041
1042 2023-02-01 Tobias Burnus <tobias@codesourcery.com>
1043
1044 * openmp.cc (resolve_omp_clauses): Check also for
1045 power of two.
1046
1047 2023-01-29 Mikael Morin <mikael@gcc.gnu.org>
1048
1049 PR fortran/108450
1050 * check.cc (gfc_check_minloc_maxloc): Explicitly set argument name.
1051 (gfc_check_findloc): Ditto.
1052
1053 2023-01-29 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1054
1055 PR fortran/103506
1056 * parse.cc (parse_module): Remove use of a bool error value
1057 that prevented proper setting of the namespace pointer.
1058
1059 2023-01-28 Harald Anlauf <anlauf@gmx.de>
1060 Steven G. Kargl <kargl@gcc.gnu.org>
1061
1062 PR fortran/108527
1063 * resolve.cc (compare_bound_int): Expression to compare must be of
1064 type INTEGER.
1065 (compare_bound_mpz_t): Likewise.
1066 (check_dimension): Fix comment on checks applied to array section
1067 and clean up associated logic.
1068
1069 2023-01-28 Harald Anlauf <anlauf@gmx.de>
1070
1071 PR fortran/108453
1072 * match.cc (gfc_match_common): A USE associated name shall not appear
1073 in a COMMON block (F2018:C8121).
1074
1075 2023-01-27 Tobias Burnus <tobias@codesourcery.com>
1076
1077 PR fortran/108558
1078 * trans-openmp.cc (gfc_split_omp_clauses): Handle has_device_addr.
1079
1080 2023-01-26 Harald Anlauf <anlauf@gmx.de>
1081
1082 PR fortran/108544
1083 * resolve.cc (check_host_association): Extend host association check
1084 so that it is not restricted to functions. Also prevent NULL pointer
1085 dereference.
1086
1087 2023-01-25 Steve Kargl <kargl@gcc.gnu.org>
1088
1089 PR fortran/108528
1090 * array.cc (compare_bounds): Return false instead of generating an
1091 internal error on an invalid argument type.
1092
1093 2023-01-24 Harald Anlauf <anlauf@gmx.de>
1094
1095 PR fortran/108529
1096 * simplify.cc (simplify_transformation): Do not try to simplify
1097 transformational intrinsic when the ARRAY argument has a NULL shape.
1098
1099 2023-01-23 Harald Anlauf <anlauf@gmx.de>
1100
1101 PR fortran/108502
1102 * dependency.cc (gfc_check_dependency): Prevent NULL pointer
1103 dereference while recursively checking expressions.
1104
1105 2023-01-23 Harald Anlauf <anlauf@gmx.de>
1106
1107 PR fortran/108501
1108 * interface.cc (get_expr_storage_size): Check array subscript triplets
1109 that we actually have integer values before trying to extract with
1110 mpz_get_si.
1111
1112 2023-01-23 Harald Anlauf <anlauf@gmx.de>
1113
1114 PR fortran/108420
1115 * iresolve.cc (check_charlen_present): Preserve character length if
1116 there is no array constructor.
1117
1118 2023-01-21 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1119
1120 PR fortran/102595
1121 * data.cc (gfc_assign_data_value): Remove check for PARAMETER in DATA.
1122 * primary.cc (match_variable): Add check for PARAMETER in DATA.
1123
1124 2023-01-19 Harald Anlauf <anlauf@gmx.de>
1125
1126 PR fortran/108434
1127 * expr.cc (class_allocatable): Prevent NULL pointer dereference
1128 or invalid read.
1129 (class_pointer): Likewise.
1130
1131 2023-01-17 Harald Anlauf <anlauf@gmx.de>
1132
1133 PR fortran/108421
1134 * interface.cc (get_expr_storage_size): Check that we actually have
1135 an integer value before trying to extract it with mpz_get_si.
1136
1137 2023-01-12 Tobias Burnus <tobias@codesourcery.com>
1138
1139 PR fortran/107706
1140 * openmp.cc (gfc_resolve_omp_assumptions): Reject nonscalars.
1141
1142 2023-01-11 Jakub Jelinek <jakub@redhat.com>
1143
1144 PR fortran/108349
1145 * f95-lang.cc (gfc_init_builtin_function): Fix up function types
1146 for BUILT_IN_REALLOC and BUILT_IN_SINCOS{F,,L}. Formatting fixes.
1147
1148 2023-01-10 Harald Anlauf <anlauf@gmx.de>
1149
1150 PR fortran/97345
1151 * frontend-passes.cc (do_subscript): Clear used gmp variables.
1152
1153 2023-01-02 Jakub Jelinek <jakub@redhat.com>
1154
1155 * gfortranspec.cc (lang_specific_driver): Update copyright notice
1156 dates.
1157 * gfc-internals.texi: Bump @copying's copyright year.
1158 * gfortran.texi: Ditto.
1159 * intrinsic.texi: Ditto.
1160 * invoke.texi: Ditto.
1161
1162 \f
1163 Copyright (C) 2023 Free Software Foundation, Inc.
1164
1165 Copying and distribution of this file, with or without modification,
1166 are permitted in any medium without royalty provided the copyright
1167 notice and this notice are preserved.