A character self-defining term consists of 1-to-4 characters enclosed
in apostrophes, and must be preceded by the letter
C. All letters,
decimal digits, and special characters can be used in a character
self-defining term. In addition, any of the remaining EBCDIC characters
can be designated in a character self-defining term. Examples of character
self-defining terms are:
C'/'
C' ' (space)
C'ABC'
C'13'
Because of the use of apostrophes in the assembler language and
ampersands in the macro language as syntactic characters, the following
rule must be observed when using these characters in a character self-defining
term:
- For each apostrophe or ampersand you want in a character self-defining
term, two apostrophes or ampersands must be written. For example,
the character value A'# is written as 'A''#',
while a single apostrophe followed by a space and another apostrophe
is written as ''' '''.
For C-type character self-defining terms, each character in the character sequence
is assembled as its 8 bit code equivalent.
For more
details, refer to the web page “Coded Character Set Reference
Material”, which is located at: http://www.ibm.com/software/globalization/g11n-res.html
The two apostrophes or ampersands that must be used to represent
an apostrophe or ampersand within the character sequence are assembled
as an apostrophe or ampersand. Double-byte data can appear in a character
self-defining term, if the DBCS assembler option is specified. The
assembled value includes the SO and SI delimiters. Hence a character
self-defining term containing double-byte data is limited to one double-byte
character delimited by SO and SI. For example,
C'<.A>'.
Since the SO and SI are stored, the null double-byte character
string, C'<>', is also a valid
character self-defining term.
Note: The assembler does not support character self-defining terms
of the form CU'x' because self-defining terms are required by definition
of the Assembler Language to have fixed values.
The following Invariant characters have the same encoding
(binary value) in all EBCDIC code pages. When you enter an invariant
character you can be sure that the resulting binary value does not
depend on which EBCDIC code page your input device (editor) is using.
It will display or print as the same character regardless of which
EBCDIC code page the output device (display or printer) is using.