1! { dg-do run }
2! tests basic block data functionality
3! we didn't allow multiple block data program units
4block data
5 common /a/ y(3)
6 data y /3*1./
7end
8
9blockdata d1
10 common /a/ w(3)
11 common /b/ u
12 data u /1./
13end blockdata d1
14
15block data d2
16 common /b/ u
17 common j ! { dg-warning "blank COMMON but initialization is only allowed in named common" }
18 data j /1/
19end block data d2
20!
21! begin testing code
22common /a/ x(3)
23common /b/ y
24common i
25
26if (any(x /= 1.)) call abort ()
27if (y /= 1. .or. i /= 1) call abort ()
28end
29