next up previous contents index
Next: SIC SYSTEM Up: SIC Previous: SIC SEARCH   Contents   Index


SIC SYNTAX

          SYNTAX of SIC commands
     and
        [SIC\]SIC SYNTAX [FIXED|FREE]

    The SIC syntax is the following :
        [LANG\]COMM [Arg1 [Arg2 [...]]] [/OPT1 [p1 [...]] [/OPT2 [...]]
    where [] indicates optional fields.

    Language, command and options can be  abbreviated.  The  language  field
    (LANG\) is optional but may help resolve ambiguities.

    First,  the  line  is stripped of duplicate separators (spaces or tabs).
    Character strings (entities included between double quotes) are not  af-
    fected by this formatting.

    Then  symbols  (entities  included  between simple quotes, plus the lan-
    guage-command field) and tokens (macros  parameters  1  2  etc...)   are
    translated, even within character strings.

    Finally,  the line is analysed for ambiguities and the language, command
    and option names are expanded. An option is a word beginning by a  slash
    (e.g. /OPT1 is an option in the above example).

    All arguments can be character or mathematical variables or expressions,
    depending on the type required by the program. Character expressions can
    be  concatenated  with implicit formatting of variables and mathematical
    expressions, such as in
        "The real number PI is equal to "'ACOS(-1.0)'
    Variable and expressions are not evaluated during the parsing, but  only
    during  the  execution.  Character  variables  must  be included between
    quotes for translation, e.g.
          DEFINE CHARACTER C*6
          LET C 3.14159
          DEFINE REAL A
          LET A 'C'/PI
          EXAMINE A
            A       =    0.9999705

        [SIC\]SIC SYNTAX [FIXED|FREE]

    controls the syntax for mathematic operations. In FIXED syntax, the  LET
    command is compulsory. In FREE syntax, commands lines like
           A[I,J] = SIN((2*I+J)/PI)
    where A is a known variable, are recognized as assignement and automati-
    cally expanded to the equivalent FIXED syntax
           LET A[I,J] SIN((2*I+J)/PI)
    Free syntax cannot be used for the LET /WHERE command.


Gildas manager 2024-03-28