From: David E. <de...@us...> - 2008-10-12 03:04:45
|
m_amass wrote: ... > i have some problem wit compiling my third Cobol source, htcobol hang-up. > The source is from one book from 1988. (See attachment.) > ... > Is the problem only on my system or is it a generic problem? This a bug related to the TC COBOL grammar and Bison. It occurs once in a while with no apparent reason or warning. The syntax in question is 'CONSOLE IS CRT' in the 'SPECIAL-NAMES' clause. TC does NOT currently support this syntax. TC should just trap this as an error and print the error message. When the TC COBOL grammar is compiled with YACC193 [1] (Berkeley's YACC version 1.9.3), the same syntax will print an error message and exit normally. I have no idea how to fix this bug, other than suggesting using YACC193. Just change the code as follows and it should compile and run. SPECIAL-NAMES. DECIMAL-POINT IS COMMA * CONSOLE IS CRT . *INPUT-OUTPUT SECTION. *FILE-CONTROL. ... VERARBEITUNG SECTION. VER-1000. *DISPLAY SPACE UPON CRT. ... BTW, if you using the fixed COBOL source format, to avoid problems add the '-F' or '--fixed' option to the command line. Hope this helps. 1) Berkeley's YACC version 1.9.3 (byacc) can be downloaded only from the TC 'snapshot' web page. |