Contents | Prev | Next | Index
The syntax of expressions specifies operator precedences according to four classes of operators. The NOT-operator, @-operator, and the unary operators "+" or "-" have the highest binding strength, followed by multiplication operators, addition operators, and finally relational operators. Operators of the same binding strength associate from left to right. For example, x-y-z stands for (x-y)-z.
expr ::= simple_expr relation simple_expr
::= simple_expr
simple_expr ::= simple_expr add_operator term
::= term
term ::= term mul_operator factor
::= factor
factor ::= primary
::= sub_expr
::= sub_expr selector_list
sub_expr ::= ( expr )
primary ::= chr_const
::= <integer>
::= <real>
::= <string>
::= set
::= expr_designator
::= proc_designator actual_parameters
::= not factor
::= unary factor
::= @ expr_designator
set ::= [ elem_list ]
::= [ ]
elem_list ::= elem_list , elem
::= elem
elem ::= elem_expr .. elem_expr
::= elem_expr
elem_expr ::= expr
relation ::= =
::= <>
::= <
::= <=
::= >
::= >=
::= IN
::= IS
add_operator ::= +
::= -
::= OR
::= XOR
mul_operator ::= *
::= /
::= DIV
::= MOD
::= AND
::= SHL
::= SHR
::= AS
not ::= NOT
unary ::= +
::= -
|
Contents | Prev | Next | Index
Canterbury Pascal for JVM (Last documentation update
Jun 9, 2000)
Copyright © 1998 Mill Hill & Canterbury
Corporation, Ltd. All rights reserved
Please send any comments or corrections to
mhc@webcom.com