All commands parsed by SIC must have the following syntax:
[LANG]COMM [ARG1 [ARG2 [...]]] [/OPT1 [ARG11 [...]] [/OPT2 [...]]
Where LANG is the language name, COMM the command name, OPT1 and OPT2 are option names, ARGs are the arguments of command and options, and brackets indicate optional fields.
The language, command and option names can be abbreviated and SIC checks for ambiguities. Arguments are separated by any number of separators (Blanks or Tabs). An option is a word beginning with a Slash. The options, like the commands, may have arguments. The syntax analyzer converts to upper case letters, strips useless separators, translate the symbols (See 2.5), expands the command and option names by looking through its current ``dictionary''.
The language field is optional. If present, it restricts the resolution of command name abbreviations to all languages of which it is an abbreviation. Otherwise, all languages are searched for.
The first action of the syntax analyzer is to suppress redundant separators. This is of course not always wanted (e.g. a figure caption) and SIC offers one way to circumvent this problem: the so-called strings, which are arguments included between double quotes ("). Strings are not modified by the syntax analyzer, but the outer double quotes will be ignored when the argument is used. However, strings are not protected against symbol substitution.
The program calling SIC may expect arguments of various types: character strings, real numbers, integers or logicals. For a specified type, e.g. a real number, the argument can be either a constant value (e.g. 3.14159), a variable (e.g. PI), or an expression (e.g. 2*ASIN(-1.0)). Conversion to the specified type is done automatically if possible at all (See 2.13).
A ``-'' sign as the last significant character in a command line indicates that a continuation follows on the next line (as in DCL command language) e.g.
SIC> HELP - SIC> EDITis interpreted as
SIC> HELP EDIT
No special procedure is used to cut strings for continuation lines. It is simply done according to the following example
SIC> LABEL "A very long- SIC> string must be cut"which is interpreted as
SIC> LABEL "A very long string must be cut"
Comments may appear at the end of any line. The comment area starts with a ``'' sign; all the following text is ignored. Comments can be used in conjunction with the continuation mark :
SIC> DRAW RELOCATE 13- !This is an example of comments SIC> .45 15.00 /USER ! and continuationis interpreted as
SIC> DRAW RELOCATE 13.45 15.00 /USERBUT do not try this one
SIC> LABEL "A lon- ! A long string SIC> g caption" ! with continuation markwhich produces the message
E-INTER, Unbalanced quote countimmediately after the first line as been typed in, because the syntax analyzer was considering the - and signs as part of a string. Comments may be convenient to self-document complex procedures.