HLASM Language Reference

HLASM Language Reference HLASM Language Reference

faculty.cs.niu.edu
from faculty.cs.niu.edu More from this publisher
22.02.2015 Views

MNOTE Instruction When two literals specifying identical A-type, Y-type or S-type address constants contain a reference to the value of the location counter (*), both literals are assembled into the literal pool. This is because the value of the location counter may be different in the two literals. Even if the location counter value is the same for both, they are still both assembled into the literal pool. The following examples show how the assembler stores pairs of literals, if the placement of each pair is controlled by the same LTORG statement. =X'F' Both are =C'' stored =XL3'' =HL3'' =A(+4) =A(+4) =X'FFFF' =X'FFFF' Both are stored Both are stored Identical, only one copy is stored MNOTE Instruction The MNOTE instruction generates your own error messages or displays intermediate values of variable symbols computed during conditional assembly. The MNOTE instruction can be used inside macro definitions or in open code, and its operation code can be created by substitution. The MNOTE instruction causes the generation of a message that is given a statement number in the printed listing. ►►──┬─────────────────┬──MNOTE───┬───────────┬─message─────────────►◄ └─sequence_symbol─ ┘ ├ ─severity,─┤ ├─,────────┤ └─,─────────┘ sequence_symbol is a sequence symbol. severity is a severity code. The severity operand may be any absolute expression allowed in the operand field of a SETA instruction. The term must have a value in the range 0 through 255. The severity code is used to determine the return code issued by the assembler when it returns control to the operating system. The severity may also change the value of the system variable symbols &SYSM_HSEV and &SYSM_SEV (see “&SYSM_HSEV System Variable Symbol” on page 279 and “&SYSM_SEV System Variable Symbol” on page 280). message is the message text. It may be any combination of characters enclosed in single quotation marks. The rules that apply to this character string are as follows: 196 HLASM V1R5 Language Reference

MNOTE Instruction Variable symbols are allowed. The single quotation marks that enclose the message can be generated from variable symbols. Two ampersands and two single quotation marks are needed to generate an ampersand or a single quotation mark, respectively. If variable symbols have ampersands or single quotation marks as values, the values must be coded as two ampersands or two single quotation marks. If the number of characters in the character string plus the rest of the MNOTE operand exceeds 1024 bytes the assembler issues diagnostic message | Note: The maximum length of the second operand is three less than the | maximum supported length of SETC character string. ASMA62E Illegal operand format The notation can be used as a continuation. Here is an example taken from a CICS® macro: MNOTE 8,'FIELD IS DEFINED OUTSIDE OF THE SIZE OPERAND' MNOTE ,'PARAMETERS SPECIFIED IN THE DFHMDI MACRO,' MNOTE ,'MACRO REQUEST IS IGNORED.' A further advantage of this approach is that only one severity 8 error is seen instead of three. Double-byte data is permissible in the operand field when the DBCS assembler option is specified. The double-byte data must be valid. The DBCS ampersand and apostrophe are not recognized as delimiters. A double-byte character that contains the value of an EBCDIC ampersand or apostrophe in either byte is not recognized as a delimiter when enclosed by SO and SI. Remarks: Any remarks for the MNOTE instruction statement must be separated by one or more spaces from the single quotation mark that ends the message. If severity is provided, or severity is omitted but the comma separating it from message is present, the message is treated as an error message; otherwise the message is treated as comments. The rules for specifying the contents of severity are: The severity code can be specified as any arithmetic expression allowed in the operand field of a SETA instruction. The expression must have a value in the range 0 through 255. Example: MNOTE 2,'ERROR IN SYNTAX' The generated result is: 2,ERROR IN SYNTAX If the severity code is omitted, but the comma separating it from the message is present, the assembler assigns a default value of 1 as the severity code. Example: MNOTE ,'ERROR, SEV 1' The generated result is: Chapter 5. Assembler Instruction Statements 197

MNOTE Instruction<br />

Variable symbols are allowed. The single quotation marks that enclose the<br />

message can be generated from variable symbols.<br />

Two ampersands and two single quotation marks are needed to generate<br />

an ampersand or a single quotation mark, respectively. If variable symbols<br />

have ampersands or single quotation marks as values, the values must be<br />

coded as two ampersands or two single quotation marks.<br />

If the number of characters in the character string plus the rest of the<br />

MNOTE operand exceeds 1024 bytes the assembler issues diagnostic<br />

message<br />

| Note: The maximum length of the second operand is three less than the<br />

| maximum supported length of SETC character string.<br />

ASMA62E Illegal operand format<br />

The notation can be used as a continuation.<br />

Here is an example taken from a CICS® macro:<br />

MNOTE 8,'FIELD IS DEFINED OUTSIDE OF THE SIZE OPERAND'<br />

MNOTE ,'PARAMETERS SPECIFIED IN THE DFHMDI MACRO,'<br />

MNOTE ,'MACRO REQUEST IS IGNORED.'<br />

A further advantage of this approach is that only one severity 8 error is<br />

seen instead of three.<br />

Double-byte data is permissible in the operand field when the DBCS<br />

assembler option is specified. The double-byte data must be valid.<br />

The DBCS ampersand and apostrophe are not recognized as delimiters.<br />

A double-byte character that contains the value of an EBCDIC ampersand<br />

or apostrophe in either byte is not recognized as a delimiter when enclosed<br />

by SO and SI.<br />

Remarks: Any remarks for the MNOTE instruction statement must be separated<br />

by one or more spaces from the single quotation mark that ends the message.<br />

If severity is provided, or severity is omitted but the comma separating it from<br />

message is present, the message is treated as an error message; otherwise the<br />

message is treated as comments. The rules for specifying the contents of severity<br />

are:<br />

The severity code can be specified as any arithmetic expression allowed in the<br />

operand field of a SETA instruction. The expression must have a value in the<br />

range 0 through 255.<br />

Example:<br />

MNOTE 2,'ERROR IN SYNTAX'<br />

The generated result is:<br />

2,ERROR IN SYNTAX<br />

If the severity code is omitted, but the comma separating it from the message<br />

is present, the assembler assigns a default value of 1 as the severity code.<br />

Example:<br />

MNOTE ,'ERROR, SEV 1'<br />

The generated result is:<br />

Chapter 5. Assembler Instruction Statements 197

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!