Statement Syntax

Gilda declarations and commands begin with a verb followed by arguments, except for assignments and subroutine calls. Commands are not case sensitive. A pretty printer program can apply standard formatting rules to source code. You can enter programs in lower case and the pretty printer will adjust the case and indent code blocks.

To comment a command, delimit it with a lead colon, semicolon or ampersand. Use the ampersand to indicate the command is continued on the following line. A source line ending in a comma is also implicitly continued.

     : This is a comment only line.
     :
     Variable = I * 2 + 1;            The semicolon is a comment delimiter.

     IF Variable = 0:                 IF commands use a colon by convention.
        Variable = Lower                &This assignment is continued.
                 + function( A, B )

        : This next command is continued due to the comma at the end.
        :
        PRINT  "The values are: ", A, B,
                                   Variable
     .

A block of source code can also be commented out. A comment block begins with a line that starts with "<<". All text is ignored until reaching a line that begins with ">>". The remaining text on that line is also ignored as a comment. The beginning and end lines may also be indented with leading spaces.

      <<<<<<<< This is the beginning of a comment block.
      Whatever goes in between is ignored as a comment.
      >>>>>>>> This line ends the block.

Gilda Overview

Function Procedure