* is not attached to the jump itself
*/
if (E2 != 0 &&
- (E2->Info & OF_UBRA) != 0 &&
+ (E2->Info & OF_UBRA) != 0 &&
E2->JumpTo &&
E2->JumpTo->Owner != E2) {
*/
if (In->RegY >= 0 && /* Value of Y is known */
E->AM == AM65_ZP && /* Store into zp */
- In->RegX == RegVal (E->Chg, In)) { /* Value identical */
+ In->RegY == RegVal (E->Chg, In)) { /* Value identical */
Delete = 1;
} else if (!IsClassInt (rhst)) {
Error ("Incompatible types");
} else {
- /* Adjust the int types. To avoid manipulation of TOS mark lhs
- * as const.
- */
+ /* Convert the rhs to the type of the lhs. */
unsigned flags = TypeOf (rhst);
if (rhs->Flags == E_MCONST) {
flags |= CF_CONST;
}
- return g_typeadjust (TypeOf (lhst) | CF_CONST, flags);
+ return g_typecast (TypeOf (lhst), flags);
}
} else if (IsClassPtr (lhst)) {
if (IsClassPtr (rhst)) {
case TC_INCOMPATIBLE:
Error ("Incompatible pointer types");
break;
-
+
case TC_QUAL_DIFF:
Error ("Pointer types differ in type qualifiers");
break;
return CF_INT;
}
-
+
void DefineData (ExprDesc* Expr)
/* Output a data definition for the given expression */
lflags |= TypeOf (lval->Type) | CF_FORCECHAR;
rflags |= TypeOf (lval2.Type);
- /* Adjust the rhs to the lhs. To avoid manipulation of the TOS, mark
- * the lhs as const.
- */
- g_typeadjust (lflags | CF_CONST, rflags);
+ /* Cast the rhs to the type of the lhs */
+ g_typecast (lflags, rflags);
/* Output apropriate code */
if (lval->Flags & E_MGLOBAL) {