PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gfortran.dg / character_comparison_7.f90
blob1f132cac73698819cb2310e4dd025db1af8d86d7
1 ! { dg-do run }
2 ! { dg-options "-O -fdump-tree-original" }
3 ! Test that expressions in subroutine calls are also optimized
4 program main
5 implicit none
6 character(len=4) :: c
7 c = 'abcd'
8 call yes(c == c)
9 call no(c /= c)
10 end program main
12 subroutine yes(a)
13 implicit none
14 logical, intent(in) :: a
15 if (.not. a) STOP 1
16 end subroutine yes
18 subroutine no(a)
19 implicit none
20 logical, intent(in) :: a
21 if (a) STOP 2
22 end subroutine no
24 ! { dg-final { scan-tree-dump-times "gfortran_compare_string" 0 "original" } }