re PR fortran/36724 (ICE: (character pointer targets substring))
authorDaniel Franke <dfranke@gcc.gnu.org>
Sun, 27 Jul 2008 16:32:14 +0000 (12:32 -0400)
committerDaniel Franke <dfranke@gcc.gnu.org>
Sun, 27 Jul 2008 16:32:14 +0000 (12:32 -0400)
2008-07-27  Daniel Franke  <franke.daniel@gmail.com>

PR fortran/36724
* gfortran.dg/pointer_to_substring.f90: New test.

From-SVN: r138190

gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/pointer_to_substring.f90 [new file with mode: 0644]

index 7bdc31bbeaad21e7dd191df715c3fd0f7ac2b927..95b0cde4944c2a411ca8ad8a730eb23e26ffba91 100644 (file)
@@ -1,11 +1,16 @@
+2008-07-27  Daniel Franke  <franke.daniel@gmail.com>
+
+       PR fortran/36724
+       * gfortran.dg/pointer_to_substring.f90: New test.
+
 2008-07-27  Tobias Burnus  <burnus@net-b.de>
 
        PR fortran/36132
        PR fortran/29952
        PR fortran/36909
-       gfortran.dg/internal_pack_4.f90: New.
-       gfortran.dg/internal_pack_5.f90: New.
-       gfortran.dg/array_temporaries_2.f90: New.
+       gfortran.dg/internal_pack_4.f90: New.
+       gfortran.dg/internal_pack_5.f90: New.
+       gfortran.dg/array_temporaries_2.f90: New.
 
 2008-07-26  Thomas Koenig  <tkoenig@gcc.gnu.org>
 
diff --git a/gcc/testsuite/gfortran.dg/pointer_to_substring.f90 b/gcc/testsuite/gfortran.dg/pointer_to_substring.f90
new file mode 100644 (file)
index 0000000..054a29d
--- /dev/null
@@ -0,0 +1,10 @@
+! { dg-do compile }
+! PR36724 - ICE on pointer to substring
+! testcase contributed by Loukas Peristeras.
+
+  character(LEN=132), target :: line
+  character(LEN=1), pointer :: t
+
+  read(*,'(A)') line
+  t=>line(1:1)
+end