You are here: start » ppl » source_syntax

PPL source syntax

PPL source syntax

Each line of a PPL source file may contain none, one, some or all of the following sections:

[KEYWORD ][EXPRVAR][,EXPRVAR][;'][COMMENT TEXT]
KEYWORDA PPL statement used to accomplish some task.
EXPRA PPL expression which may contain VARs, CONSTs, and/or FUNCs.
VARA PPL variable with optional array subscript.
CONSTA PPL constant.
FUNCA PPL function that returns a value.
;Used to start a comment. Ignored by the compiler.
'Used to start a comment. Ignored by the compiler.
*Used to start a comment if first character of the line.
COMMENTComment text following the ; or '. Ignored by the compiler

If a line is blank or contains only a comment, it is skipped. if it contains a KEYWORD, that line is compiled into a tokenized format. If it doesn't contain a KEYWORD but some argument, it is assumed to be an assignement statement (LET).

A double quote (“”) may be embedded within a string constant to tell the compiler that a single literal quote is desired In other words, “THIS”“IS”“A”“TEST” would evaluate to THIS“IS”A“TEST after the leading and trailing quotes are removed and the double quotes were folded to single quotes.
Labels and variable names may now include the following characters in addition to A-Z, 0-9, and the _ (underscore) character: $ (dollar sign), @ (commercial at), # (pound sign), ¢ (cents), £ (british pound), ¥ (japanese yen)
A \ (backslash) character as the last character on a line (before any comments) will now allow continuing a logical line from one to the next physical line
A : (colon) character may be used to separate multiple logical lines on a single physical line

Tags: ppl syntax

ppl/source_syntax.txt · Last modified: 2019/04/12 14:26
CC Attribution 4.0 International Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution 4.0 International