re PR fortran/54633 (ICEs and reject valid with MINLOC/MINVAL (MAXLOC/MAXVAL) due...
authorThomas Koenig <tkoenig@gcc.gnu.org>
Sun, 24 Sep 2017 13:51:39 +0000 (13:51 +0000)
committerThomas Koenig <tkoenig@gcc.gnu.org>
Sun, 24 Sep 2017 13:51:39 +0000 (13:51 +0000)
2017-09-24  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/54633
* gfortran.dg/intrinsic_bounds_1.f90: New test.
* gfortran.dg/intrinsic_param_1.f90: New test.

From-SVN: r253125

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

index bc23562b1b92cb7b00c3922a0b0326aaebcdc971..3502b3ac80511130576686406dc4cde6f091b685 100644 (file)
@@ -1,3 +1,9 @@
+2017-09-24  Thomas Koenig  <tkoenig@gcc.gnu.org>
+
+       PR fortran/54633
+       * gfortran.dg/intrinsic_bounds_1.f90: New test.
+       * gfortran.dg/intrinsic_param_1.f90: New test.
+
 2017-09-24  Thomas Koenig  <tkoenig@gcc.gnu.org>
            Steven G. Kargl  <kargl@gcc.gnu.org>
 
diff --git a/gcc/testsuite/gfortran.dg/intrinsic_bounds_1.f90 b/gcc/testsuite/gfortran.dg/intrinsic_bounds_1.f90
new file mode 100644 (file)
index 0000000..a9586fb
--- /dev/null
@@ -0,0 +1,7 @@
+! { dg-do compile }
+! PR 54633 - this used to be rejected
+program main
+  integer :: x(minval((/1/),mask=(/.TRUE./)))
+  integer, parameter :: m = minval((/1/))
+  integer :: y(minval((/1/),mask=(/.TRUE./)))
+end
diff --git a/gcc/testsuite/gfortran.dg/intrinsic_param_1.f90 b/gcc/testsuite/gfortran.dg/intrinsic_param_1.f90
new file mode 100644 (file)
index 0000000..7c168a7
--- /dev/null
@@ -0,0 +1,6 @@
+! { dg-do compile }
+! { dg-additional-options "-std=f95" }
+! PR 54633 - this used to be accepted
+program main
+  integer, parameter :: m = minval((/1/)) ! { dg-error "Transformational function" }
+end