return;
}
- /* If we have a struct pointer that is an lvalue and not already in the
+ /* If we have a struct pointer that is an lvalue and not already in the
* primary, load it now.
*/
if (ED_IsLVal (Expr) && IsTypePtr (Expr->Type)) {
case TOK_STAR:
NextToken ();
- if (evalexpr (CF_NONE, hie10, Expr) != 0) {
- /* Expression is not const, indirect value loaded into primary */
- ED_MakeRValExpr (Expr);
- }
+ ExprWithCheck (hie10, Expr);
+ if (ED_IsLVal (Expr) || !(ED_IsLocConst (Expr) || ED_IsLocStack (Expr)))) {
+ /* Not a const, load it into the primary and make it a
+ * calculated value.
+ */
+ ExprLoad (CF_NONE, Expr);
+ ED_MakeRValExpr (Expr);
+ }
/* If the expression is already a pointer to function, the
* additional dereferencing operator must be ignored.
*/
case TOK_AND:
NextToken ();
- hie10 (Expr);
+ ExprWithCheck (hie10, Expr);
/* The & operator may be applied to any lvalue, and it may be
* applied to functions, even if they're no lvalues.
*/
* a numeric constant, cast to any type.
*/
{
- return ED_IsConst (Expr) && ED_IsLocAbs (Expr);
+ return (Expr->Flags & (E_MASK_LOC|E_MASK_RTYPE)) == (E_LOC_ABS|E_RTYPE_RVAL);
}