HP Pascal/iX Reference Manual (31502-90022)

6-: 2
Compound Statements
A
compound
statement is a sequence of statements bracketed by the
reserved words BEGIN and END. A semicolon (;) delimits one statement from
the next. Certain statements may alter the flow of execution in order to
achieve effects such as selection, iteration, or invocation of another
procedure or function. For instance, after the last statement in the
body of a routine has executed, control is returned to the point in the
program from which the routine is called. Note the use of non-local
GOTOs voids this statement. The program terminates after the last
statement is executed.
A compound statement has two primary uses. First, it defines the
statement part of a block and second, it groups a series of statements
into a single statement. A compound statement may also serve to
logically group a series of statements.
Note that compound statements are allowed, but are unnecessary in the
following cases:
* The statements between REPEAT and UNTIL.
* The statements between OTHERWISE and the end of the CASE
statement.