Update concepts branch to revision 131834
[official-gcc.git] / gcc / testsuite / gfortran.fortran-torture / execute / strcommon_1.f90
blobaa51ccf4bae33ffa43fabde4281317109963bd9d
1 ! PR14081 character variables in common blocks.
3 subroutine test1
4 implicit none
5 common /block/ c
6 character(len=12) :: c
8 if (c .ne. "Hello World") call abort
9 end subroutine
11 subroutine test2
12 implicit none
13 common /block/ a
14 character(len=6), dimension(2) :: a
16 if ((a(1) .ne. "Hello") .or. (a(2) .ne. "World")) call abort
17 end subroutine
19 program strcommon_1
20 implicit none
21 common /block/ s, t
22 character(len=6) :: s, t
23 s = "Hello "
24 t = "World "
25 call test1
26 call test2
27 end program