Match: Support more form for scalar unsigned SAT_ADD
[official-gcc.git] / gcc / testsuite / gfortran.dg / dec_char_conversion_in_assignment_1.f90
blob9dc2ece1efd008d334438b3f13059f50626ee6ca
1 ! { dg-do run }
2 ! { dg-options "-fdec" }
4 ! Modified by Mark Eggleston <mark.eggleston@codethink.com>
6 program test
7 integer(4) :: a
8 real(4) :: b
9 complex(4) :: c
10 logical(4) :: d
11 integer(4) :: e
12 real(4) :: f
13 complex(4) :: g
14 logical(4) :: h
16 a = '1234'
17 b = '1234'
18 c = '12341234'
19 d = '1234'
20 e = 4h1234
21 f = 4h1234
22 g = 8h12341234
23 h = 4h1234
25 if (a.ne.e) stop 1
26 if (b.ne.f) stop 2
27 if (c.ne.g) stop 3
28 if (d.neqv.h) stop 4
30 ! padded values
31 a = '12'
32 b = '12'
33 c = '12234'
34 d = '124'
35 e = 2h12
36 f = 2h12
37 g = 5h12234
38 h = 3h123
40 if (a.ne.e) stop 5
41 if (b.ne.f) stop 6
42 if (c.ne.g) stop 7
43 if (d.neqv.h) stop 8
45 ! truncated values
46 a = '123478'
47 b = '123478'
48 c = '12341234987'
49 d = '1234abc'
50 e = 6h123478
51 f = 6h123478
52 g = 11h12341234987
53 h = 7h1234abc
55 if (a.ne.e) stop 5
56 if (b.ne.f) stop 6
57 if (c.ne.g) stop 7
58 if (d.neqv.h) stop 8
60 end program