Marc's Place

DIBIOL/DBL - Synergy Language Compiler


SYNERGYDBL

Use the DIBOL command to invoke the Synergy DBL compiler. The DIBOL command line has one of the following formats: DIBOL [/qualifiers] file1[/qualifiers][,...filen[/qualifiers]] DIBOL [/qualifiers] file1 [+...filen][/qualifiers]

Parameters

The parameters to the DIBOL command are the Synergy DBL source files to be compiled. If you specify more than one source file to be compiled then you must separate them with either a comma (,) or a plus sign (+). If you use a comma, each source file is compiled separately, producing separate object files. If you use a plus sign however, the files are concatenated and compiled to produce a single object file.
    file1 The first source file to be compiled. At least one source file must be specified. The default file name extension is .DBL filen The optional name(s) of additional source files to be compiled. The default file name extension is .DBL

Qualifiers

Is an optional string that contains one or more of the compiler options and their arguments. You must precede each option with a slash (/). If a qualifier requires an argument and that argument is not specified, Synergy DBL assumes that the qualifiers argument is the main filename. You can append one or more compiler options either to the DIBOL command or to an individual source file. If you append compiler options to the DIBOL command then all source files are affected by the option. Options appended to a source file name however, only affect that single file. /ALTSTORE /ALTSTORE /NOALTSTORE (default) Alternate DIBOL compatible decimal to decimal and alpha to decimal moves. I you expect a decimal to decimal move where the source conatins a mixture of spaces and digits to be converted to digits only, specify ALTSTORE. NOTE: there is a performance penalty for using this switch at run time. /ALTIF /ALTIF /NOALTIF (default) Alternate IF. Use the alternate (non ANSI DIBOL) form of the IF statement, which specifies that the THEN is optional and the ELSE belongs to the last IF statement. The default is /NOALTIF. The ANSI DIBOL form of the IF statement specifies that each ELSE belongs to the most recent THEN in the same lexical level. For more information, refer to the IF statement in on page 4-60 of the Synergy DBL Language Reference Manual. /BIND /BIND /BIND=qualifier Compile file1 as a primary or secondary routine for a bound program, where qualifier is one of the two keywords, PRIMARY or SECONDARY. The source file name is the first source file specified, without an extension. By default, Synergy DBL does not compile a bound program. NOTE: Bind is not currently implemented
PRIMARY
/BIND=PRIMARY
Compile the specified source file as a primary routine for the
bound program.
SECONDARY
/BIND=SECONDARY
Compile the specified source file as a secondary routine for
the bound program.
/COMMON /COMMON=EXTERNAL /COMMON=NOSUFFIX Process COMMON statements according to the specified keyword, where keyword is either EXTERNAL or NOSUFFIX.
EXTERNAL
Treat a COMMON statement that doesn't specify a GLOBAL or
EXTERNAL qualifier in the main routine as an external common.
By default, Synergy DBL treats these COMMON statements as
global commons.
NOSUFFIX
Do not append a "$" to the end of common variable names. By
default, Synergy DBL adds the suffix "$" to all common variables.
/DEBUG /DEBUG /NODEBUG (default) Create a symbolic access table. The compiler will output symbol names for all variables into the object file. The default value for this qualifier is /NODEBUG. /DECARGS /DECARGS /NODECARGS (default) Numeric argument. Map all decimal type arguments to numeric type. The default value is /NODECARGS. /DIGITAL /DIGITAL /NODIGITAL (Default) Use the VAX DIBOL compiler instead of the Synergy DBL compiler /FIND_LOCK /FIND_LOCK /NOFIND_LOCK (default) Have the FIND statement default to locking the specified record. By default, Synergy DBL does not lock the record unless you specify the LOCK qualifier on the FIND statement. /GBLDEFS /GBLDEFS (default) /NOGBLDEFS Determines if the DBLDIR:DBL.DEF file is included into your programs. The DBL.DEF file defines several operating system symbols such as D_AXP and D_VMS, so that you can conditionally compile your code depending on the operating system that you are running on. The file also defines numerous values for I/O qualifiers. If you end a routine with the END statement (instead of .END), the DBL.DEF identifiers will be cleared along with any identifiers you have defined. If your routines end with an END and you want to use the identifiers defined in DBL.DEF then you must either explicitly .INCLUDE the DBL.DEF file in any routine that will use the identifiers, or replace all of your final END statements with .END and remove duplicate .INCLUDE statements throughout the file. /LISTING /NOLISTING (default) /LISTING=filename Generate a program listing named 'filename'. If you don't specify 'filename', then the default list file name is the name of the first source file with the extension .LIS and the file is created in the current directory. By default, Synergy DBL does not generate program listings /OBJECT /NOOBJECT /OBJECT=filename Name the object file filename. The default object file name is the name of the first source file, with the extension .OBJ and the file is placed in the current directory. If you don't want to specify an object file name then you must specify /NOOBJECT. /OFFSETS /OFFSETS /NOOFFSETS (default) Symbol table offsets. Create a table of every symbol referenced in a program at the end of each routine in a listing. The default value for this parameter is /NOOFFSETS. /OPTIMIZE /OPTIMIZE /NOOPTIMIZE (default) Remove the line number information from the executable image. The resulting code is smaller, but does not execute any faster. If you specify this option then you will not be able to use DEBUG and any error tracebacks will not include line numbers. The default value is /NOOPTIMIZE /PAGE_SIZE /PAGE_SIZE=length Set the length of each page of the program listing to length. If this option is not specified then the default program listing page length is 60 lines. /REFRESH /REFRESH /NOREFRESH (default) Refresh the data from the disk between invocations. The default is /NOREFRESH NOTE: Refresh is not currently implemented. /SHOW /SHOW (default) /SHOW=(option[,...]) Generate extra information to the listing file. By default, Synergy DBL will generate a listing file containing source files, conditional compiler directives, source code within false conditional blocks and page headers and footers. By default, if a listing file is being created then all items are included, equivalent to specifying /SHOW, or /SHOW=ALL. You can modify the contents of the listing file by specifying one or more of the following options:
ALL
/SHOW=ALL
Show all options. This option is equivalent to specifying
/SHOW with no options.
CONDITIONALS
/SHOW=CONDITIONALS (default)
/SHOW=NOCONDITIONALS
If you wish to exclude conditional compiler directives and source
code within false conditional blocks from the program listing then
specify NOCONDITIONALS. The default is CONDITIONALS.
HEADERS
/SHOW=HEADERS (default)
/SHOW=NOHEADERS
If you want to exclude page headers and footers from the program
listing then specify NOHEADERS. The default is HEADERS.
NEWPAGE
/SHOW=NEWPAGE
/SHOW=NONEWPAGE (default)
Form feed immediately after the data division in the program
listing. The default is NONEWPAGE.
USAGE
/SHOW=USAGE
/SHOW=NOUSAGE (default)
Summarize the amount of memory required for each program
component and generate a memory usage summary table in the
program listing. The default is NOUSAGE.
/STREAM Change the default submode for files opened in output mode to 'STREAM'. If you don't specify this option then files which are opened in output mode will be sequential. /VARIANT /VARIANT /VARIANT=value Define the value of the %VARIANT compile-time option. If you do not specify the value, the default variant value is 1. /WARNINGS /WARNINGS (default) /NOWARNINGS If you do not wish to generate any warnings during the compilation then specify /NOWARNINGS. The default value is /WARNINGS. /WIDTH_SIZE /WIDTH_SIZE=length Set the width of the program listing to 'width' columns. If this option is not specified then the default program listing width is 132 columns.

Environment

The following logical names affect the way that Synergy DBL operates in an OpenVMS environment: DBL_CHRSET The optional logical name DBL_CHRSET is used by DEC terminals to specify character sets other than US ASCII for the windowing subroutines. $ DEFINE DBL_CHRSET "escape_sequence"
Escape_Sequences
Is the escape sequence that designates the character set of
an associated language should be used for all screen display:
(B US ASCII
(A British
(4 Dutch
(Q French Canadian
(R French
(K German
(Y Italian
(Z Spanish
(= Swiss
Refer to your VMS Terminal Programming Guide for more details.
You can also refer to a specific terminals programming manual
for other sequences.
Note that the escape character is NOT a part of the logical
name's definition. It is supplied by the DBL runtime.
Example
$ DEFINE DBL_CHRSET "(K"
Instructs the windowing system to use the German character set.
DBLDICTIONARY The optional logical name DBLDICTIONARY indicates the file specifications for the Synergy ICS Data Dictionary files. $ DEFINE DBLDICTIONARY "file1,file2" Where file1 is the specification of the Data Dictionary main file, and file2 is the specification of the Data Dictionary text file. The two file specifications must be enclosed in quotes and comma separated.
Example
$DEFINE DBLDICTIONARY "DDMAIN.ICS,DDTEXT.ICS"
DBLDIR The DBLDIR logical name tells Synergy DBL which directory contains your Synergy DBL software distribution. This logical name is required for normal operation of Synergy DBL tools and programs, and is defined by the Synergy startup procedure SYS$MANAGER:SYNERGY_STARTUP.COM. $ DEFINE DBLDIR device:[directory]
Example
$ DEFINE/SYS/EXEC DBLDIR SYS$SYSDEVICE:[SYNERGY.DBL]
DBLLIBRARY The optional DBLLIBRARY logical name indicates the directory that the compiler will search for files specified in any .INCLUDE statements that use the LIBRARY option without specifying a library location. $ DEFINE DBLLIBRARY directory
directory
The 'directory' parameter can be either a single directory
specification, or a search list of two or more directories
separated by commas. If a search list is used then DO NOT
include the directory specifications in quotes.
Examples
$ DEFINE DBLLIBRARY SYS$SYSDEVICE:[MYLIB]
The above example instructs the Synergy DBL compiler to
search for included library modules in the system directory
SYS$SYSDEVICE:[MYLIB]
$ DEFINE DBLLIBRARY SYS$SYSDEVICE:[MYLIB],DBL$ROOT:[DBLSTARLET]
This second example shows the use of a VMS search list. The
Synergy DBL compiler will first search for included library
modules in the SYS$SYSDEVICE:[MYLIB] directory, but if the
required module is not located there the compiler will then
search in the DBL$ROOT:[DBLSTARLET] directory.
DBLMAXERR The optional DBLMAXERR logical name specifies the maximum number of errors that the Synergy DBL compiler will generate before abandoning the compilation with a "Too many errors" error. By default the Synergy DBL compiler will abort a compilation after 20 errors have been detected. $ DEFINE DBLMAXERR error_count
Example
$ DEFINE DBLMAXERR 50
The above example instructs the Synergy DBL compiler to abort
a compilation after the detection of 50 errors.
DBLOPT The optional DBLOPT logical name specifies Synergy DBL system options which modify the product's environment or functionality. $ DEFINE DBLOPT string
string
A string that contains one or more Synergy DBL system option
numbers, separated by commas. Synergy DBL will ignore any
unrecognised option numbers which appear in the string, and
any which are not applicable to OpenVMS.
Options
Summary
1 Default SEND queue
2 Default file specification on STOP
5 CRT mode
7 Synergy Daemon
9 ---Obsolete---
10 Interrupt character
11 Rounding vs. truncation
12 Buffered terminal I/O
13 Default SEND queue
14 ---obsolete---
15 -- NON VMS only -- File pre-allocation
16 Quit character
17 Terminal number returned by XCALL TNMBR
18 In-place MERGE and logical end-of-file
20 ---obsolete---
21 Interrupt trapping
22 LPQUE ststement
23 In-place merge and duplicate records
24 --TSX32 only -- <Ctrl-B>, <Ctrl-D>, and <Ctrl-E>
25 ---Obsolete---
26 Detached terminal send
27 ---obsolete---
28 Mapping decimal data to numeric
29 Dimensioned variable
30 Default terminal definition
31 IF statement format
32 Upper and Lower casing
35 Dibol Compatibility
36 Default to ALTMOVE in the compiler
1
System option 1 determines the default terminal number for
the SEND statement. If you set option 1, the default terminal
number will be 255, and the message being sent will be inserted
into the global message queue.
System option 13 also sets the default terminal number, and it
overrides option 1. If option 13 is set then option 1 is ignored.
If you don't set option 1 or 13 and you don't specify a terminal
number in a SEND statement, the default terminal number will
be the number of the terminal running the program. The message
will be inserted into the terminals local message queue.
2
System option 2 controls the default file specification for the
STOP statement.
If you set option 2, the filename extension and path will default
to the extension and path of the program requesting the chain. If
option 2 is not set then the file extension will default to .EXE
and the path will default to the current directory.
5
System option 5 determines whether terminal I/O should be interpreted
as being CRT I/O. If you set option 5, Synergy DBL will assume that
terminal I/O is I/O to or from a CRT. This option acts the same as
XCALL FLAGS runtime option flag 4. If you don't set this option then
CRT mode will be reset upon program startup and any I/O is assumed
to be non-CRT I/O.
7
System option 7 determines whether the runtime will use the Synergy
Message Manager or the local message facilities. Setting system
option 7 will cause the Synergy Message Manager to be used.
10
System option 10 controls whether or not the interrupt
character will be ignored at program startup and between
chains. If option 10 is set, the interrupt character will
be ignored at program startup and between chained programs,
and the state of XCALL FLAGS runtime option 8 will automatically
be set on entry to each program. You can control when the
interrupt character will be processed (in other words, not
ignored) throughout your program by unsetting and resetting
flag 8. If you don't set this option, Synergy DBL will
process any interrupt character the user types, unless
flag 8 is set.
11
System option 11 determines whether Synergy DBL will round
or truncate expression results by default. With option 11
set, Synergy DBL will truncate results, with option 11 not
set, results are rounded.
For a detailed discussion of this system option refer to
your Synergy DBL Language Reference Manual.
12
System option 12 affects buffered terminal output. If you
set option 12 then the Synergy DBL runtime will buffer
output until the buffer is full, a sleep, xcall tflsh, xcall wait
xcall spawn or terminal I/O statement occurs.
NOTE: this is currently not implemented.
13
System option 13 determines the default terminal number
for the SEND statement. If you set option 13, the default
terminal number will be 254, and the message being sent
will be inserted into the group message queue.
System option 1 also sets the default terminal number, but
is overriden by option 13. If option 13 is set, option 1
is ignored.
If you don't set option 13 or 1 and you don't specify a terminal
number in a SEND statement, the default terminal number will
be the number of the terminal running the program. The message
will be inserted into the terminals local message queue.
14
System option 14 is now obsolete and is ignored.
15
System option 15 is now obsolete and is ignored.
16
System option 16 maps the quit character to the interrupt
character. If you set option 16, when the user presses the
quit character, it will have the same effect as pressing
the interrupt character. For example, <Ctrl-Y> will have
the same effect as <Ctrl-C>. If option 16 is not set, then
the quit character will quit out of the program.
NOTE: Under OpenVMS, you can continue program execution
by issuing a DCL CONTINUE command.
17
System option 17 controls how XCALL TNMBR determines the
terminal number. With option 17 set, TNMBR will use the
physical device to determine the terminal number for a
virtual terminal. If option 17 is not set TNMBR will
return the unit number in the VT device specification
for a virtual terminal.
18
System option 18 controls how the in-place MERGE statement
handles the logical end-of-file in the primary file. With
option 18 set, the in-place MERGE will extend the primary
file by the number of records merged from the secondary
file. All records past the logical end-of-file in the
primary file are copied to the end of the primary file's
extension.
If option 18 is not set, the in-place MERGE treats any
logical end-of-file character or record as the end of the
usable data in the primary file. Any records that follow
the logical end-of-file will be overwritten.
20
(MS-DOS ONLY)
System option 20 is now obsolete and is ignored.
21
System option 21 determines whether or not the interrupt
character is trappable. With option 21 set, the ONERROR
statement cannot trap the interrupt character, which
means that the user can press the interrupt character to
interrupt your program. Without this option the ONERROR
statement will trap the interrupt, which may make it
difficult to abort your program.
22
System option 22 determines how the LPQUE statement will
interface to the operating system. With option 22 set,
and a program running from an interactive process, the
LPQUE statement will spawn a PRINT statement to print
a specified file, which enables you to add print options
after the filename. Without this option set, or for
programs NOT running from an interactive process, the
LPQUE statement will use the $SNDJBC system service to
print the specified file. Any switches that follow the
file name will be ignored. This feature works within batch
or detached processes. You cannot use wildcard characters
in the file name.
NOTE: The operation of option 22 is system specific.
23
System option 23 determines where an in-place MERGE
statement places duplicate records. With option 23 set,
the in-place MERGE will place duplicate records from the
second input file after their matching records from the
first file. Without option 23 set, the duplicate records
are placed before the matching record from the first file.
24
(TSX-32 ONLY)
System option 24 controls the processing of <Ctrl-B>,
<Ctrl-D>, and <Ctrl-E> characters under the TSX-32
operating system.
25
(MS-DOS ONLY)
System option 25 is now obsolete and is ignored.
26
(VMS ONLY)
System option 26 only affects detached processes. It looks
for a device name that can be used for terminal-directed
SEND's. With option 26 set, the Synergy DBL program will
examine the logical names SYS$INPUT, SYS$OUTPUT, and
SYS$ERROR, in that order, for the first one that has been
assigned to a terminal device. The Synergy DBL program
gets the device characteristics of the translation of each
of these logicals. If one of the logicals is a terminal
device, that device name will be communicated to the
Synergy Daemon. The device name can then be used for
terminal-dircted SEND's by other programs.
If option 26 is not set, the detached process can only
receive messages sent to either the global or group
queues. Messages cannot be sent directly to their local
queue.
NOTE: Terminal-directed SEND's cannot be done to programs
running iun a sub-process, detached process, batch process,
or network process if system option 26 is not set.
27
System option 27 is now obsolete and is ignored.
28
System option 28 causes the compiler to map decimal
subroutine arguments (d) to numeric (n). With this
option set, the compiler will treat any subroutine
arguments declared as 'd', as type 'n'. If this option
is not set then no mapping of the decimal data type
will occur.
29
System option 29 determines whether the compiler requires
dimension specifications on a dimensioned variable. With
option 29 set, any dimensioned variable which is referenced
without dimension specifications ( [ ] ) will cause Synergy
DBL to to generate a "Dimension specifications required {var}"
compilation error. Dimension specifications are NOT required
on subroutine arguments or arguments to the ^PASSED data
reference operation. Without option 29 set, Synergy DBL will
not require dimension specifications on dimensioned variables.
30
System option 30 controls screen clearing for the Synergy
Windows routines. Set this option to optimize screen
clearing by these routines.
31
System option 31 determines which IF statement format the
Synergy DBL compiler will recognise. With option 31 set,
the compiler will use the alternate form of the IF statement
during compilation, instead of the ANSI dibol form. Using
the alternate IF syntax, an ELSE clause matches the prtevious
IF clause. ANSI DIBOL IF syntax, on the other hand, matches
the ELSE clause with the previous THEN caluse. If option 31
is not set, the compiler defaults to the ANSI DIBOL syntax
for the IF satement.
32
System option 32 eliminates the upper and lower casing of
all two-byte characters. With option 32 set, the upper and
lower casing of the Kanji language and all other two-byte
characters will be eliminated.
5 35
System option 35 provides VAX-DIBOL compatible functionality
for the following features:
- OPEN TT:
- Echoing control charactrers
- XCALL RENAM
- OPEN with O:P mode
- Allow input from keyboard as TT: rather than the command file
when running from a command file.
Example
$ DEFINE DBLOPT "7,16,30,35"
DBLSTARLET The optional DBLSTARLET logical name specifies the directory of the system .INCLUDE files for use within system services. By default value is DBL$ROOT:[DBLSTARLET] $ DEFINE DBLSTARLET device:[directory] Note: This logical name is defined by the Synergy startup procedure SYS$MANAGER:SYNERGY_STARTUP.COM
Example
$ DEFINE DBLSTARLET DBL$ROOT:[DBLSTARLET]
DBLTEXT The optional DBLTEXT logical name specifies the directory of the .INCLUDE files that are for use with the Synergy DBL external subroutines. the default directory specification is DBL$ROOT:[DBLSTARLET]. $ DEFINE DBLTEXT device:[directory] Note: This logical name is defined by the Synergy startup procedure SYS$MANAGER:SYNERGY_STARTUP.COM
Example
$ DEFINE DBLTEXT DBL$ROOT:[DBLSTARLET]
TNMBR The optional logical name TNMBR specifies the number that Synergy DBL will use as the current terminal number. It is your responsibility to ensure that you do not assign the same terminal number to more than one terminal. $ DEFINE TNMBR number
number
The number that you want XACLL TNMBR to return for your terminal.
Example
$ DEFINE TNMBR 5
WNDC The optional WNDC logical name will enable color on color terminals and define the default Synergy colors. Screens are updated using standard ANSI color escape sequences. $ DEFINE WNDC "palette1[,palette2,...,palette16]"
palettes
Each color palette specification (palette1, palette2 etc)
defines the foreground and background colors for that palette,
in the form forground/background. Forground and background
are single character codes which signify a color.
You may skip a palette entry by placing successive commas in
the string. Any omitted palette entries default to the entry
for palette 1. The background color for palette entry 1 is
the background color for the entire screen.
Color_codes
D Dark (black) R Red
B Blue M Magenta
G Green G Green
C Cyan W White
Example
$ DEFINE WNDC "G/B,R/Y,,D/W"
The above example specifies that palette entry 1 be green
characters on a blue background, entry 2 is red characters
on a yellow background, and entry 4 is black characters on
a white background. All other palette entries will default
to green characters on a blue background (as palette 1).

VMS_Specific

General Below is a list of features that are specific to Synergy DBL statements under OpenVMS. These statements are described in further detail in chapter 4 of your Synergy DBL Language Reference Manual. - OpenVMS does not support the ^LAST qualifier on the FIND, READ, or WRITE statements. - OpenVMS does not support the ^EOF qualifier on the WRITE statement. - The DETACH statement is not available under OpenVMS. - The DISPLAY statement is valid only on channels opened to a terminal, Synergy DBL stream, or sequential files opened for output or append mode, and print files opened in output or append mode. Opening TT:, where the terminal output is redirected to a disk file, will result in separate records for each DISPLAY statement on VMS - The GET, GETS, PUT, and PUTS binary I/O statements are only available on channels opened to Synergy DBL stream files, not any other file type. Note, however, that it is more efficient to open a file in BLOCK sub-mode and then access the file with the standard READ and WRITE statements than it is to access the file using the binary I/O statements previously mentioned. - If your program is interactive and you set system option 22, the LPQUE statement spawns a PRINT command to print a specified file. Refer to documentation of system option 22 for further information. - If you're creating a relative file on OpenVMS, the RECSIZ I/O qualifier is required. If you're opening a relative file for input, the RECSIZ qualifier is checked and an "Invalid record size" error ($ERR_IRCSIZ) occurs if the values do not match the maximum record size defined for the file. - The KEYNUM I/O qualifier with a non-zero value is not supported on a READ statement that uses the RFA I/O qualifier. - The DIRECTION qualifier is not supported on the READS statement for ISAM files. Subroutines Several subroutines are either only available on Synergy DBL for OpenVMS, or have diferent functionality under OpenVMS from other operating systems.
VMS_only
The following subroutines are ONLY available under the
OpenVMS operating system. Refer to chapter 6 of your
Synergy DBL Language Reference Manual for a complete
description of these subroutines.
DBL$CPUTM
DBL$CREMBX
DBL$DELMBX
DBL$DEVCLT
DBL$EXECUTE_IMAGE_ROUTINE
DBL$GETCM
DBL$GETFA
DBL$JBNAM
DBL$PARSE
DBL$PUTCM
DBL$TTCHAR
DBL$TTFLGS
DBL$TT_NAME_TO_NUMBER
DBL$TT_NUMBER_TO_NAME
DBL$WKDAY
VMS_different
The following external subroutines function differently under
OpenVMS than they do under other operating systems. Refer to
chapter 6 of your Synergy DBL Language Reference Manual for
a complete description of these subroutines.
BTOD
DTOB
CMDLN
DELET
ERROR
FATAL
FLAGS
GLINE
ISAMC
JBNO
KILL
POSRFA
RENAM
TNMBR
WAIT
SPAWN
© 1997- Marc Vos (and others) Contact Me