Variable Declaration

The Macro Assembler can provide a way to associated a type with a symbol which is defined externally. This is done by extending the XREF syntax:

    
  XREF var: typeName, var2 
  

where:

var2 is the name of another externally defined symbol. This symbol is not associated with any type. See the following listing for an example.

Listing: Example of extending XREF

myType: STRUCT
field1:   DS.W 1

field2:   DS.W 1

field3:   DS.B 1

field4:   DS.B 3

field5:   DS.W 1

        ENDSTRUCT

        XREF extData: myType ; var `extData' is type `myType'