summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/g77/le.f
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gfortran.dg/g77/le.f')
-rw-r--r--gcc/testsuite/gfortran.dg/g77/le.f30
1 files changed, 30 insertions, 0 deletions
diff --git a/gcc/testsuite/gfortran.dg/g77/le.f b/gcc/testsuite/gfortran.dg/g77/le.f
new file mode 100644
index 000000000..c62ac46cd
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/g77/le.f
@@ -0,0 +1,30 @@
+c { dg-do run }
+ program fool
+
+ real foo
+ integer n
+ logical t
+
+ foo = 2.5
+ n = 5
+
+ t = (n > foo)
+ if (t .neqv. .true.) call abort
+ t = (n >= foo)
+ if (t .neqv. .true.) call abort
+ t = (n < foo)
+ if (t .neqv. .false.) call abort
+ t = (n <= 5)
+ if (t .neqv. .true.) call abort
+ t = (n >= 5 )
+ if (t .neqv. .true.) call abort
+ t = (n == 5)
+ if (t .neqv. .true.) call abort
+ t = (n /= 5)
+ if (t .neqv. .false.) call abort
+ t = (n /= foo)
+ if (t .neqv. .true.) call abort
+ t = (n == foo)
+ if (t .neqv. .false.) call abort
+
+ end