Example

In the example in the following listing, the expression tabEnd-tabBegin evaluates to an absolute expression and is assigned the value of the difference between the offset of tabEnd and tabBegin in the section DataSec.

Listing: Absolute expression relating the difference between two relocatable symbols
DataSec:  SECTION
tabBegin: DS.B  5

tabEnd:   DS.B  1

ConstSec: SECTION

label:    EQU tabEnd-tabBegin     ; Absolute expression

CodeSec:  SECTION

entry:    NOP