5.8.14. ASSERT directive

The ASSERT directive generates an error message during the second pass of the assembly if a given assertion is false.

Syntax

The syntax of ASSERT is:

ASSERT logical-expression

where:

logical-expression

is an assertion that can evaluate to either {TRUE} or {FALSE}.

Usage

Use ASSERT to ensure that any necessarycondition is met during assembly.

If the assertion is false an error message is generated and assembly fails.

See also INFO or ! directive.

Example

		ASSERT		label1 <= label2					; Tests if the address 
									; represented by label1
									; is <= the address 
									; represented by label2.
Copyright © 1997, 1998 ARM Limited. All rights reserved.ARM DUI 0041C
Non-Confidential