[PATCH] PR fortran/101327 - ICE in find_array_element, at fortran/expr.c:1355
Harald Anlauf
anlauf@gmx.de
Mon Aug 30 21:40:21 GMT 2021
There was an issue when trying to use an element from an array constructor
which was a broken in a way probably only Gerhard could conceive.
We hit an assert that can be replaced by more robust code.
Patch is basically Steve's.
Regtested on x86_64-pc-linux-gnu. OK for mainline?
Thanks,
Harald
Fortran - improve error recovery determining array element from constructor
gcc/fortran/ChangeLog:
PR fortran/101327
* expr.c (find_array_element): When bounds cannot be determined as
constant, return error instead of aborting.
gcc/testsuite/ChangeLog:
PR fortran/101327
* gfortran.dg/pr101327.f90: New test.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr101327.patch
Type: text/x-patch
Size: 1433 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20210830/86be043f/attachment.bin>
More information about the Gcc-patches
mailing list