From 50389094cc83594333d124581d737d35c8527c98 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tobias=20Schl=C3=BCter?= Date: Sat, 10 Jul 2004 19:54:35 +0200 Subject: [PATCH] re PR fortran/15969 (ICE and assertion failure in trans-expr.c) PR fortran/15969 * gfortran.fortran-torture/execute/der_init_5.f90: New test. From-SVN: r84466 --- gcc/testsuite/ChangeLog | 5 +++++ .../execute/der_init_5.f90 | 16 ++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 gcc/testsuite/gfortran.fortran-torture/execute/der_init_5.f90 diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 94d75b8246d..7ae23fd8b28 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2004-07-10 Tobias Schlueter + + PR fortran/15969 + * gfortran.fortran-torture/execute/der_init_5.f90: New test. + 2004-07-10 David Billinghurst (David.Billinghurst@riotinto.com) * gfortran.dg/g77/ffixed-form-1.f: Copy from g77.dg diff --git a/gcc/testsuite/gfortran.fortran-torture/execute/der_init_5.f90 b/gcc/testsuite/gfortran.fortran-torture/execute/der_init_5.f90 new file mode 100644 index 00000000000..22c0c33ba2f --- /dev/null +++ b/gcc/testsuite/gfortran.fortran-torture/execute/der_init_5.f90 @@ -0,0 +1,16 @@ +! Check that null initialization of pointer components works. +! PR 15969 prompted these +! the commented out tests are cases where we still fail +program der_init_5 + type t + type(t), pointer :: a => NULL() + real, pointer :: b => NULL() +! character, pointer :: c => NULL() +! integer, pointer, dimension(:) :: d => NULL() + end type t + type (t) :: p + if (associated(p%a)) call abort() + if (associated(p%b)) call abort() +! if (associated(p%c)) call abort() +! if (associated(p%d)) call abort() +end -- 2.30.2