aboutsummaryrefslogtreecommitdiff
path: root/gcc/expr.cc
diff options
context:
space:
mode:
authorHarald Anlauf <anlauf@gmx.de>2023-03-11 15:37:37 +0100
committerHarald Anlauf <anlauf@gmx.de>2023-03-11 15:48:32 +0100
commit2cf5f485e0351bb1faf46196a99e524688f3966e (patch)
tree304530d15d7a1d824b8b7478de49c2d17d8772c7 /gcc/expr.cc
parentc62df15d283f035d5b1644f74493db2933f2a8cb (diff)
downloadgcc-2cf5f485e0351bb1faf46196a99e524688f3966e.zip
gcc-2cf5f485e0351bb1faf46196a99e524688f3966e.tar.gz
gcc-2cf5f485e0351bb1faf46196a99e524688f3966e.tar.bz2
Fortran: fix bounds check for copying of class expressions [PR106945]
In the bounds check for copying of class expressions, the number of elements determined from a descriptor, returned as type gfc_array_index_type (i.e. a signed type), should be converted to the type of the passed element count, which is of type size_type_node (i.e. unsigned), for use in comparisons. gcc/fortran/ChangeLog: PR fortran/106945 * trans-expr.cc (gfc_copy_class_to_class): Convert element counts in bounds check to common type for comparison. gcc/testsuite/ChangeLog: PR fortran/106945 * gfortran.dg/pr106945.f90: New test.
Diffstat (limited to 'gcc/expr.cc')
0 files changed, 0 insertions, 0 deletions