unsigned PSizeOf (const Type* T) /* Compute size of pointer object. */ { /* We are expecting a pointer expression */ CHECK (IsClassPtr (T)); /* Skip the pointer or array token itself */ return SizeOf (T + 1); }
int ED_IsBool (const ExprDesc* Expr) /* Return true of the expression can be treated as a boolean, that is, it can * be an operand to a compare operation. */ { /* Either ints, floats, or pointers can be used in a boolean context */ return IsClassInt (Expr->Type) || IsClassFloat (Expr->Type) || IsClassPtr (Expr->Type); }
Type* Indirect (Type* T) /* Do one indirection for the given type, that is, return the type where the ** given type points to. */ { /* We are expecting a pointer expression */ CHECK (IsClassPtr (T)); /* Skip the pointer or array token itself */ return T + 1; }