Skip to content
Snippets Groups Projects
Commit 91e6e982 authored by rdubner's avatar rdubner
Browse files

UAT for DECLARATIVES with and without following SECTION

parent c3bf9a86
No related branches found
No related tags found
No related merge requests found
Pipeline #2312 failed
......@@ -1000,4 +1000,25 @@ AT_DATA([prog.cob], [ identification division.
])
AT_CHECK([$COMPILE prog.cob], [1], [], [cobol1: error: -main switch says "prog.cob" should contain the starting program, but none was found
])
AT_CLEANUP
\ No newline at end of file
AT_CLEANUP
AT_SETUP([DECLARATIVES with following SECTION])
AT_KEYWORDS([DECLARATIVES])
AT_DATA([prog.cob], [ identification division.
program-id. prog.
procedure division.
DECLARATIVES.
declaratives-ec-all section.
use after exception condition ec-all.
display " declarative for ec-all".
end declaratives.
display "hello".
end program prog.
])
AT_CHECK([$COMPILE prog.cob], [1], [], [prog.cob:9: error: ISO programs with DECLARATIVES must begin with a SECTION unless -dialect ibm
cobol1: error: failed compiling prog.cob
])
AT_CHECK([$COMPILE -dialect ibm prog.cob], [0], [], [])
AT_CLEANUP
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment