READLOCK Function

Taking only one memory cycle, the READLOCK function stores the value of the specified expression in the designated variable and returns the previous contents of the variable.

The READLOCK function has three forms. One form returns a real value, one form returns a Boolean value, and one form returns a pointer. The following form of the READLOCK function stores the value of the arithmetic expression in the arithmetic variable and returns the previous contents of the variable as a real value. Both the variable and the expression must be single-precision.

── READLOCK ── ( ──<arithmetic expression>── , ──<arithmetic variable>─►
►─ ) ──────────────────────────────────────────────────────────────────┤

The following form of the READLOCK function stores the value of the Boolean expression in the Boolean variable and returns the previous contents of the variable as a Boolean value:

── READLOCK ── ( ──<Boolean expression>── , ──<Boolean variable>── ) ──┤

The following form of the READLOCK function stores the value of the pointer expression in the pointer variable and returns the previous contents of the variable as a pointer value.

── READLOCK ── ( ──<pointer expression>── , ──<pointer variable>── ) ──┤