Chapter 10: Expressions and Symbols in Debugger Commands
Character Strings and Character Constants
Character Strings. A character string is a sequence of one or more ASCII
characters enclosed in double quotation marks or two or more characters
enclosed in single quotes. If the string has more than one character,
subsequent ASCII characters are stored in consecutive bytes.
When a character string is referenced in a C expression, the debugger
substitutes an address pointer to the string in the expression.
Character Constants. A character constant is a single character enclosed in
single quotation marks.
When a character constant is referenced in a C expression, the debugger
substitutes the actual ASCII character value in the expression, not the address
of the character.
You can use # define constants in debugger expressions if your compiler places
the constant in the absolute file.
Non-printable characters. Some non-printable characters may be
embedded in both character strings and character constants enclosed in double
quotation marks (") by using the escape sequences listed in the table which
follows. Escape sequences are indicated by a backslash (\).
The backslash is interpreted as a character in character strings enclosed in
single quotation marks (').
Any characters other than those listed in the following table are interpreted
literally if preceded by a backslash. For example, to have literal double
quotation marks in a string, enclose the string in double quotation marks and
use the escape sequence for double quotes shown above. For example:
"This is a \"string\" using embedded double quotation
To have literal single quotation marks in a character string, enclose the string
in double quotation marks. For example: