transfer.c (transfer_array_inner): Do not cast charlen to index_type.
authorUros Bizjak <ubizjak@gmail.com>
Tue, 26 Feb 2019 18:41:53 +0000 (19:41 +0100)
committerUros Bizjak <uros@gcc.gnu.org>
Tue, 26 Feb 2019 18:41:53 +0000 (19:41 +0100)
* io/transfer.c (transfer_array_inner): Do not
cast charlen to index_type.

From-SVN: r269224

libgfortran/ChangeLog
libgfortran/io/transfer.c

index 0941b5876fd9975d078f93452bd3fdc974976b6d..25db8c65b7d479503087289f22505d2f0f3409bd 100644 (file)
@@ -1,3 +1,8 @@
+2019-02-26  Uroš Bizjak  <ubizjak@gmail.com>
+
+       * io/transfer.c (transfer_array_inner): Do not
+       cast charlen to index_type.
+
 2019-02-25  Dominique d'Humieres  <dominiq@gcc.gnu.org>
 
        PR libfortran/89274
 2019-01-09  Sandra Loosemore  <sandra@codesourcery.com>
 
        PR other/16615
-
        * caf/single.c: Mechanically replace "can not" with "cannot".
        * io/unit.c: Likewise.
 
index 247fb6d2a9c07188e7e34c658770dbf55358ded9..c43360f6332b3510c2e790986ac0b6a7ed96f15d 100644 (file)
@@ -2496,7 +2496,7 @@ transfer_array_inner (st_parameter_dt *dtp, gfc_array_char *desc, int kind,
     return;
 
   iotype = (bt) GFC_DESCRIPTOR_TYPE (desc);
-  size = iotype == BT_CHARACTER ? (index_type) charlen : GFC_DESCRIPTOR_SIZE (desc);
+  size = iotype == BT_CHARACTER ? charlen : GFC_DESCRIPTOR_SIZE (desc);
 
   rank = GFC_DESCRIPTOR_RANK (desc);