aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/testsuite/ChangeLog8
-rw-r--r--gcc/testsuite/gfortran.dg/allocate_derived_1.f9027
-rw-r--r--gcc/testsuite/gfortran.dg/class_7.f033
-rw-r--r--gcc/testsuite/gfortran.dg/coarray_14.f902
-rw-r--r--gcc/testsuite/gfortran.dg/typebound_proc_13.f039
5 files changed, 27 insertions, 22 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 8578075..2934e0a 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,11 @@
+2012-09-30 Janus Weil <janus@gcc.gnu.org>
+
+ * gfortran.dg/allocate_derived_1.f90: Re-enable class array checks,
+ partially reverting r170092.
+ * gfortran.dg/class_7.f03: Ditto.
+ * gfortran.dg/coarray_14.f90: Ditto.
+ * gfortran.dg/typebound_proc_13.f03: Ditto.
+
2012-09-29 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54738
diff --git a/gcc/testsuite/gfortran.dg/allocate_derived_1.f90 b/gcc/testsuite/gfortran.dg/allocate_derived_1.f90
index 6480124..d2c65ff 100644
--- a/gcc/testsuite/gfortran.dg/allocate_derived_1.f90
+++ b/gcc/testsuite/gfortran.dg/allocate_derived_1.f90
@@ -24,28 +24,27 @@
real :: r
end type
-! FIXME: uncomment and dejagnuify the lines below once class arrays are enabled
-! class(t1),dimension(:),allocatable :: x
+ class(t1),dimension(:),allocatable :: x
type(t2),dimension(:),allocatable :: y
-! class(t3),dimension(:),allocatable :: z
+ class(t3),dimension(:),allocatable :: z
-! allocate( x(1))
-! allocate(t1 :: x(2))
-! allocate(t2 :: x(3))
-! allocate(t3 :: x(4))
-! allocate(tx :: x(5)) ! { "Error in type-spec at" }
-! allocate(u0 :: x(6)) ! { "may not be ABSTRACT" }
-! allocate(v1 :: x(7)) ! { "is type incompatible with typespec" }
+ allocate( x(1))
+ allocate(t1 :: x(2))
+ allocate(t2 :: x(3))
+ allocate(t3 :: x(4))
+ allocate(tx :: x(5)) ! { dg-error "Error in type-spec at" }
+ allocate(u0 :: x(6)) ! { dg-error "may not be ABSTRACT" }
+ allocate(v1 :: x(7)) ! { dg-error "is type incompatible with typespec" }
allocate( y(1))
allocate(t1 :: y(2)) ! { dg-error "is type incompatible with typespec" }
allocate(t2 :: y(3))
allocate(t3 :: y(3)) ! { dg-error "is type incompatible with typespec" }
-! allocate( z(1))
-! allocate(t1 :: z(2)) ! { "is type incompatible with typespec" }
-! allocate(t2 :: z(3)) ! { "is type incompatible with typespec" }
-! allocate(t3 :: z(4))
+ allocate( z(1))
+ allocate(t1 :: z(2)) ! { dg-error "is type incompatible with typespec" }
+ allocate(t2 :: z(3)) ! { dg-error "is type incompatible with typespec" }
+ allocate(t3 :: z(4))
end
diff --git a/gcc/testsuite/gfortran.dg/class_7.f03 b/gcc/testsuite/gfortran.dg/class_7.f03
index d7f1c83..99fbf6f 100644
--- a/gcc/testsuite/gfortran.dg/class_7.f03
+++ b/gcc/testsuite/gfortran.dg/class_7.f03
@@ -9,8 +9,7 @@
end type t0
type t
integer :: i
-! FIXME: uncomment and dejagnuify once class arrays are enabled
-! class(t0), allocatable :: foo(3) ! { "deferred shape" }
+ class(t0), allocatable :: foo(3) ! { dg-error "deferred shape" }
end type t
! PR41608: Would ICE on missing type decl
diff --git a/gcc/testsuite/gfortran.dg/coarray_14.f90 b/gcc/testsuite/gfortran.dg/coarray_14.f90
index 3097eed..d7eb6b6 100644
--- a/gcc/testsuite/gfortran.dg/coarray_14.f90
+++ b/gcc/testsuite/gfortran.dg/coarray_14.f90
@@ -47,7 +47,7 @@ end subroutine test
program myTest
type t
end type t
-type(t), allocatable :: a[:]
+class(t), allocatable :: a[:]
allocate (t :: a) ! { dg-error "Coarray specification required in ALLOCATE statement" }
allocate (t :: a[*]) ! OK
end program myTest
diff --git a/gcc/testsuite/gfortran.dg/typebound_proc_13.f03 b/gcc/testsuite/gfortran.dg/typebound_proc_13.f03
index af486ff..98caac6 100644
--- a/gcc/testsuite/gfortran.dg/typebound_proc_13.f03
+++ b/gcc/testsuite/gfortran.dg/typebound_proc_13.f03
@@ -16,8 +16,7 @@ MODULE m
TYPE t2
CONTAINS
-! FIXME: uncomment and dejagnuify once class arrays are enabled
-! PROCEDURE, PASS :: nonscalar ! { "must be scalar" }
+ PROCEDURE, PASS :: nonscalar ! { dg-error "must be scalar" }
PROCEDURE, PASS :: is_pointer ! { dg-error "must not be POINTER" }
PROCEDURE, PASS :: is_allocatable ! { dg-error "must not be ALLOCATABLE" }
END TYPE t2
@@ -27,9 +26,9 @@ CONTAINS
SUBROUTINE myproc ()
END SUBROUTINE myproc
-! SUBROUTINE nonscalar (me)
-! CLASS(t2), INTENT(IN) :: me(:)
-! END SUBROUTINE nonscalar
+ SUBROUTINE nonscalar (me)
+ CLASS(t2), INTENT(IN) :: me(:)
+ END SUBROUTINE nonscalar
SUBROUTINE is_pointer (me)
CLASS(t2), POINTER, INTENT(IN) :: me