HLASM Language Reference
HLASM Language Reference HLASM Language Reference
Assembler Language Coding Conventions If an operand is continued after column 16, it is taken to be a comment. Also, if the continuation-indicator field is filled in on one line and you try to start a new statement after column 16 on the next line, this statement is taken as a comment belonging to the previous statement. Specify the FLAG(CONT) assembler option to instruct the assembler to issue warning messages when it suspects a continuation error in a macro call instruction. Refer to the FLAG option description in the HLASM Programmer's Guide for details about the situations that might be flagged as continuation errors. Unless it is one of the statement types listed below, nine continuation lines are allowed for a single assembler language statement. Alternative Statement Format The alternative statement format, which allows as many continuation lines as are needed, can be used for the following instructions: AGO conditional assembly statement, see “Alternative Format for AGO Instruction” on page 393 AIF conditional assembly statement, see “Alternative Format for AIF Instruction” on page 392 GBLA, GBLB, and GBLC conditional assembly statements, see “Alternative Format for GBLx Statements” on page 345 LCLA, LCLB, and LCLC conditional assembly statements, see “Alternative Format for LCLx Statements” on page 347 Macro instruction statement, see “Alternative Formats for a Macro Instruction” on page 298 Prototype statement of a macro definition, see “Alternative Formats for the Prototype Statement” on page 246 SETA, SETB, SETAF, SETCF and SETC conditional assembly statements, see “Alternative Statement Format” on page 388 Examples of the alternative statement format for each of these instructions are given with the description of the individual instruction. Continuation of double-byte data No special considerations apply to continuation: Where double-byte data is created by a code-generation program, and There is no requirement for double-byte data to be readable on a device capable of presenting DBCS characters A double-byte character string may be continued at any point, and SO and SI must be balanced within a field, but not within a statement line. Where double-byte data is created by a workstation that has the capability of presenting DBCS characters, such as the IBM 5550 multistation, or where readability of double-byte data in High Level Assembler source input or listings is required, special features of the High Level Assembler language may be used. When the DBCS assembler option is specified, High Level Assembler provides the flexibility to cater for any combination of double-byte data and single-byte data. The special features provided are: Removal of redundant SI/SO at continuation points. When an SI is placed in the end column of a continued line, and an SO is placed in the continue 16 HLASM V1R5 Language Reference
Assembler Language Coding Conventions column of the next line, the SI and SO are considered redundant and are removed from the statement before statement analysis. An extended continuation-indicator provides a flexible end column on a line-by-line basis to support any alignment of double-byte data in a source statement. The end column of continued lines may be shifted to the left by extending the continuation-indicator. To guard against accidental continuation caused by double-byte data ending in the continuation-indicator column, neither SO nor SI is regarded as a continuation-indicator. If either is used, the following warning message is issued: ASMA21W SO or SI in continuation column - no continuation assumed The examples below show the use of these features. Refer to “Double-Byte Character Set Notation” on page xvi for the notation used in the examples. Source Input Considerations Extended continuation-indicators may be used in any source statement, including macro statements and statements included by the COPY instruction. | This feature is intended for source lines containing double-byte data, however it | becomes available to all lines when the DBCS option is set. On a line with a non-space continuation-indicator, the end column is the first column to the left of the continuation-indicator which has a value different from the continuation-indicator. When converting existing programs for assembly with the DBCS option, ensure that continuation-indicators are different from the adjacent data in the end column. The extended continuation-indicators must not be extended into the continue column, otherwise the extended continuation-indicators are treated as data, and the assembler issues the following error message: ASMA25E Extended continuation column must not extend into continue column For SI and SO to be removed at continuation points, the SI must be in the end column, and the SO must be in the continue column of the next line. Examples: Name Operation Operand Continuation │ ▼ DBCS1 DC C'XXXXXXXXXXXXXXXXXXXX ' DBCS2 DC C'abcdefghijklmnopqrstuvwxyz123456789XXXX ' DBCS3 DC C'abcdefghijklmnopqrstuvXX ' DBCS1: The DBCS1 constant contains 11 double-byte characters bracketed by SO and SI. The SI and SO at the continuation point are not assembled into the operand. The assembled value of DBCS1 is: Chapter 2. Coding and Structure 17
- Page 1: High Level Assembler for MVS & VM &
- Page 4 and 5: Note! Before using this information
- Page 6 and 7: Contents Source Module . . . . . .
- Page 8 and 9: Contents Ordinary USING Instruction
- Page 10 and 11: Contents Sublists in Operands . . .
- Page 12 and 13: About this Manual This manual descr
- Page 14 and 15: IBM High Level Assembler for MVS &
- Page 16 and 17: | The Internet. You can access IBM
- Page 18 and 19: ▌C▐ The item referred to by ▌
- Page 20 and 21: Miscellany The ASCII translation t
- Page 22 and 23: Part 1. Assembler Language—Struct
- Page 24 and 25: Language Compatibility Language Com
- Page 26 and 27: Assembler Program Assembler Program
- Page 28 and 29: Relationship of Assembler to Operat
- Page 30 and 31: Coding Made Easier Linkage between
- Page 32 and 33: Character Set Compatibility with Ea
- Page 34 and 35: Assembler Language Coding Conventio
- Page 38 and 39: Assembler Language Coding Conventio
- Page 40 and 41: Assembler Language Coding Conventio
- Page 42 and 43: Assembler Language Structure Condit
- Page 44 and 45: Assembler Language Structure Machin
- Page 46 and 47: Assembler Language Structure Condit
- Page 48 and 49: Terms, Literals, and Expressions Te
- Page 50 and 51: Terms, Literals, and Expressions -
- Page 52 and 53: Terms, Literals, and Expressions As
- Page 54 and 55: Terms, Literals, and Expressions Se
- Page 56 and 57: Terms, Literals, and Expressions Fo
- Page 58 and 59: Terms, Literals, and Expressions I
- Page 60 and 61: Terms, Literals, and Expressions Th
- Page 62 and 63: Terms, Literals, and Expressions 1.
- Page 64 and 65: Terms, Literals, and Expressions
- Page 66 and 67: Terms, Literals, and Expressions
- Page 68 and 69: Terms, Literals, and Expressions Th
- Page 70 and 71: | Chapter 3. Program Structures and
- Page 72 and 73: Source Module A source module is co
- Page 74 and 75: The CSECT instruction can be used a
- Page 76 and 77: | in linker control statements for
- Page 78 and 79: This is not only convenient, but it
- Page 80 and 81: | SECT_A CSECT , Define section SEC
- Page 82 and 83: | For executable sections, the loca
- Page 84 and 85: Addressing | The System/390® and z
Assembler <strong>Language</strong> Coding Conventions<br />
If an operand is continued after column 16, it is taken to be a comment. Also, if the<br />
continuation-indicator field is filled in on one line and you try to start a new<br />
statement after column 16 on the next line, this statement is taken as a comment<br />
belonging to the previous statement.<br />
Specify the FLAG(CONT) assembler option to instruct the assembler to issue<br />
warning messages when it suspects a continuation error in a macro call instruction.<br />
Refer to the FLAG option description in the <strong>HLASM</strong> Programmer's Guide for details<br />
about the situations that might be flagged as continuation errors.<br />
Unless it is one of the statement types listed below, nine continuation lines are<br />
allowed for a single assembler language statement.<br />
Alternative Statement Format<br />
The alternative statement format, which allows as many continuation lines as are<br />
needed, can be used for the following instructions:<br />
AGO conditional assembly statement, see “Alternative Format for AGO<br />
Instruction” on page 393<br />
AIF conditional assembly statement, see “Alternative Format for AIF Instruction”<br />
on page 392<br />
GBLA, GBLB, and GBLC conditional assembly statements, see “Alternative<br />
Format for GBLx Statements” on page 345<br />
LCLA, LCLB, and LCLC conditional assembly statements, see “Alternative<br />
Format for LCLx Statements” on page 347<br />
Macro instruction statement, see “Alternative Formats for a Macro Instruction”<br />
on page 298<br />
Prototype statement of a macro definition, see “Alternative Formats for the<br />
Prototype Statement” on page 246<br />
SETA, SETB, SETAF, SETCF and SETC conditional assembly statements, see<br />
“Alternative Statement Format” on page 388<br />
Examples of the alternative statement format for each of these instructions are<br />
given with the description of the individual instruction.<br />
Continuation of double-byte data<br />
No special considerations apply to continuation:<br />
Where double-byte data is created by a code-generation program, and<br />
There is no requirement for double-byte data to be readable on a device<br />
capable of presenting DBCS characters<br />
A double-byte character string may be continued at any point, and SO and SI must<br />
be balanced within a field, but not within a statement line.<br />
Where double-byte data is created by a workstation that has the capability of<br />
presenting DBCS characters, such as the IBM 5550 multistation, or where<br />
readability of double-byte data in High Level Assembler source input or listings is<br />
required, special features of the High Level Assembler language may be used.<br />
When the DBCS assembler option is specified, High Level Assembler provides the<br />
flexibility to cater for any combination of double-byte data and single-byte data.<br />
The special features provided are:<br />
Removal of redundant SI/SO at continuation points. When an SI is placed in<br />
the end column of a continued line, and an SO is placed in the continue<br />
16 <strong>HLASM</strong> V1R5 <strong>Language</strong> <strong>Reference</strong>