intrinsic_spacing.f90: Pass arguments in the correct type.
authorRichard Henderson <rth@redhat.com>
Wed, 28 Jul 2004 22:04:28 +0000 (15:04 -0700)
committerRichard Henderson <rth@gcc.gnu.org>
Wed, 28 Jul 2004 22:04:28 +0000 (15:04 -0700)
        * gfortran.fortran-torture/execute/intrinsic_spacing.f90: Pass
        arguments in the correct type.  Don't write to constant arguments.

From-SVN: r85272

gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.fortran-torture/execute/intrinsic_spacing.f90

index ae7cd8024da79063591f983e465564ab003693a7..8cbd3dd8a51fc369c283d009e71242cf120a18ec 100644 (file)
@@ -1,3 +1,8 @@
+2004-07-28  Richard Henderson  <rth@redhat.com>
+
+       * gfortran.fortran-torture/execute/intrinsic_spacing.f90: Pass
+       arguments in the correct type.  Don't write to constant arguments.
+
 2004-07-28  Diego Novillo  <dnovillo@redhat.com>
 
        PR tree-optimization/16688
index 4fac9f1b303c53c73b9914429dd6802263e2a9d9..24b31dac2a661451764f05fabdff62d1b4622d93 100644 (file)
@@ -4,15 +4,16 @@ program test_spacing
   call test_real4(3.0)
   call test_real4(33.0)
   call test_real4(-3.)
-  call test_real4(0)
-  call test_real8(0)
+  call test_real4(0.0)
+  call test_real8(0.0_8)
   call test_real8(3.0_8)
   call test_real8(33.0_8)
   call test_real8(-33._8)
 end
-subroutine test_real4(x)
-  real x,y,t
+subroutine test_real4(orig)
+  real x,y,t,orig
   integer p
+  x = orig
   p = 24
   y = 2.0 ** (exponent (x) - p)
   t = tiny(x)
@@ -21,9 +22,10 @@ subroutine test_real4(x)
     .and. (abs (x - t) .gt. abs(x * 1e-6)))call abort
 end
 
-subroutine test_real8(x)
-  real*8 x,y,t
+subroutine test_real8(orig)
+  real*8 x,y,t,orig
   integer p
+  x = orig
   p = 53
   y = 2.0 ** (exponent (x) - p)
   t = tiny (x)