The following program used to compile with one of the 1.1 tarballs, now it does not:
identification division.
program-id. atest.
data division.
working-storage section.
01 myitems GLOBAL.
03 myit1 pic x(10).
03 myit2 pic 9.
procedure division.
a-main1
section.
move 'hello' to myit1
move 8 to myit2
display 'a-main1 atest'
display myit1
display myit2
call 'btest'
display 'bye'
goback.
identification
division.
program-id. btest common.
data division.
working-storage section.
procedure division.
b-main1 section.
display 'b-main1 atest'
display myit1
display myit2
goback.
end program btest.
end program atest.
It gives the following error:
atest.cbl: In
section 'a-main1':
atest.cbl:20: Error: COMMON may only be used in a nested program
atest.cbl:20: Error: syntax error, unexpected '.', expecting RECURSIVE or "INITIAL"
But COMMON is in the nested program, is it not?
I think this has regressed a little or perhaps my understanding of COMMON is faulty?
Gary