Expressions can refer to specific items:
short data type to denote a 2-byte integer value.
double values as objects 10 bytes (80 bits) in length, rather than 8 bytes (64 bits).
== (equal) and != (not equal) operators. The debugger distinguishes between Pascal- and C-format strings. Use the prefix \p when comparing Pascal string literals. The following expression yields a false result because it compares a C string to a Pascal string:
"Nov shmoz ka pop" == "\pNov shmoz ka pop"
¨ symbol and a register name. (Type Option-r to get the ¨ symbol.)
Expressions have the following limitations:
#define directive). They are not available to the expression evaluator, even though the source code defines them.
i++) and decrement (i--) operators, as well as assignments (i = j), are not allowed.
// The debugger cannot distinguish between x the
// int variable and x the double variable. If x is
// used in an expression, the debugger will not
// know which one to use.
void f(void)
{
int x = 0;
.
.
.
{
double x = 1.0;
.
.
.
}
}// Use long in expressions; Int32 not available typedef long Int32; // Use Rect* in expressions; RectPtr not available typedef Rect* RectPtr;
Inner, not Outer::Inner in a debugger expression.
// To refer to the i member, use Inner.i,
// not Outer::Inner.i
struct Outer
{
struct Inner
{
int i;
};
};