This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/45305] Array-valued calles to elementals are not simplified
- From: "pault at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 02 Jul 2018 07:20:58 +0000
- Subject: [Bug fortran/45305] Array-valued calles to elementals are not simplified
- Auto-submitted: auto-generated
- References: <bug-45305-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=45305
--- Comment #5 from Paul Thomas <pault at gcc dot gnu.org> ---
Author: pault
Date: Mon Jul 2 07:20:27 2018
New Revision: 262299
URL: https://gcc.gnu.org/viewcvs?rev=262299&root=gcc&view=rev
Log:
2018-07-02 Paul Thomas <pault@gcc.gnu.org>
PR fortran/45305
* expr.c : Add a prototype for scalarize_intrinsic_call.
(gfc_simplify_expr): Use scalarize_intrinsic_call for elemental
intrinsic function calls.
(scalarize_intrinsic_call): Add 'init_flag' argument. Check if
the expression or any of the actual argument expressions are
NULL. Before calling gfc_check_init_expr, check 'init_flag'.
Only simplify the scalarized expressions if there are no errors
on the stack.
(gfc_check_init_expr): Set 'init_flag' true in the call to
scalarize_intrinsic_call.
2018-07-02 Paul Thomas <pault@gcc.gnu.org>
PR fortran/45305
* gfortran.dg/scalarize_parameter_array_2.f90: New test.
Added:
trunk/gcc/testsuite/gfortran.dg/scalarize_parameter_array_2.f90
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/expr.c
trunk/gcc/testsuite/ChangeLog