return 0;
}
- /* The ternary ('?') operator is weird: the ftype of the
- * operator is the type of the condition, but it will return a
- * (possibly) different type.
- */
- if (IS_TERNARY_OP(actParm))
- {
- assert(IS_COLON_OP(actParm->right));
- assert(actParm->right->left);
- ftype = actParm->right->left->ftype;
- }
- else
- {
- ftype = actParm->ftype;
- }
+ ftype = actParm->ftype;
/* If it's a small integer, upcast to int. */
if (IS_INTEGRAL (ftype)
return tree->right->right ;
}
} else {
- TTYPE (tree) = RTYPE(tree); // #HACK LTYPE(tree).
+ TTYPE (tree) = RTYPE(tree);
TETYPE (tree) = getSpec (TTYPE (tree));
}
return tree;
{
iCode *ic;
- // bitwise operations must be done unsigned
- // WHY ? causes very bad things to happen with CSE
- // SPEC_USIGN(resType)=1;
-
left = geniCodeCast (resType, left, TRUE);
right = geniCodeCast (resType, right, TRUE);
true = ast2iCode (tree->right->left,lvl+1);
/* move the value to a new Operand */
- result = newiTempOperand (operandType (true), 0);
+ result = newiTempOperand (tree->right->ftype, 0);
geniCodeAssign (result, geniCodeRValue (true, FALSE), 0);
/* generate an unconditional goto */