A2345: Embedded type definition not allowed

[ERROR]

Description

The keyword STRUCT or UNION has been detected within a structured type definition. This is not allowed.

Note

Not all assembler backends do support structured types. Assembler not supporting them will not issue this message.

Example
  myType: STRUCT

  field1:   DS.W 1

  field2:   DS.W 1

  field3:   DS.B 1

  fieldx:   STRUCT

    xx:       DS.B 1

    yy:       DS.B 1

            ENDSTRUCT

  field4:   DS.B 3

  field5:   DS.W 1

          ENDSTRUCT
  
Tips

Define the structured type as two separate structured types.

Example
  typeX:  STRUCT

    xx:     DS.B 1

    yy:     DS.B 1

          ENDSTRUCT

  myType: STRUCT

  field1:   DS.W 1

  field2:   DS.W 1

  field3:   DS.B 1

  fieldx:   TYPE typeX

  field4:   DS.B 3


  field5:   DS.W 1

          ENDSTRUCT