Closes the currently opened segment (if any) and opens the default code segment or a segment with the name given by an optional SegmentName parameter. The .CODE directive may only be used if previous .MODEL directive has been processed.
Syntax
.CODE [SegmentName]Remarks
When the SegmentName parameter is omitted from the .CODE directive, the assembler generates a default code segment whose name is determined by the memory model as follows:
Memory Model
When operating in M510 mode, the SegmentName parameter may only be specified for those memory models that allow multiple code segments (MEDIUM, LARGE, and HUGE), and the value of the @code symbol is not altered from the default. For other modes of operation, the SegmentName parameter is allowed for any model other than TINY, and the @code symbol is updated to reflect the SegmentName value.