aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/trans-io.c
diff options
context:
space:
mode:
authorJerry DeLisle <jvdelisle@gcc.gnu.org>2019-02-23 18:07:10 +0000
committerJerry DeLisle <jvdelisle@gcc.gnu.org>2019-02-23 18:07:10 +0000
commit85627e2a9e9808c49da92b943a3c8e22106bf9aa (patch)
tree18d0a7d2159470566c6f45a2d80d1b695f4a4f0d /gcc/fortran/trans-io.c
parent3aab3d374adf1b333661a6948c586c8d665a0807 (diff)
downloadgcc-85627e2a9e9808c49da92b943a3c8e22106bf9aa.zip
gcc-85627e2a9e9808c49da92b943a3c8e22106bf9aa.tar.gz
gcc-85627e2a9e9808c49da92b943a3c8e22106bf9aa.tar.bz2
re PR fortran/84387 (Defined output does not work for a derived type that has no components)
2019-02-23 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR fortran/84387 * trans-io.c (transfer_expr): Do not return if there are no components to the derived type or class. * gfortran.dg/dtio_34.f90: New test. From-SVN: r269161
Diffstat (limited to 'gcc/fortran/trans-io.c')
-rw-r--r--gcc/fortran/trans-io.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/gcc/fortran/trans-io.c b/gcc/fortran/trans-io.c
index 9a13af4..9e7071d 100644
--- a/gcc/fortran/trans-io.c
+++ b/gcc/fortran/trans-io.c
@@ -2407,8 +2407,6 @@ transfer_expr (gfc_se * se, gfc_typespec * ts, tree addr_expr,
case_bt_struct:
case BT_CLASS:
- if (ts->u.derived->components == NULL)
- return;
if (gfc_bt_struct (ts->type) || ts->type == BT_CLASS)
{
gfc_symbol *derived;