Remove all use of forms SInt and LInt and remove intSet using just Int instead.

This commit is contained in:
David Brown 2016-08-31 18:33:53 +01:00
parent 0508097ffe
commit a1fd798f6d
62 changed files with 828 additions and 861 deletions

View file

@ -475,7 +475,7 @@ static void OPV_Entier (OPT_Node n, INTEGER prec)
static void OPV_SizeCast (LONGINT from, LONGINT to)
{
if ((from != to && (from > 4 || to > 4))) {
if ((from != to && (from > 4 || to != 4))) {
switch (to) {
case 1:
OPM_WriteString((CHAR*)"(SYSTEM_INT8)", 14);
@ -507,7 +507,7 @@ static void OPV_Convert (OPT_Node n, OPT_Struct newtype, INTEGER prec)
OPM_WriteString((CHAR*)"__SETOF(", 9);
OPV_Entier(n, -1);
OPM_Write(')');
} else if (__IN(to, 0x70)) {
} else if (to == 5) {
if ((newtype->size < n->typ->size && __IN(2, OPM_opt))) {
OPM_WriteString((CHAR*)"__SHORT", 8);
if (OPV_SideEffects(n)) {
@ -798,10 +798,10 @@ static void OPV_ActualPar (OPT_Node n, OPT_Object fp)
OPM_WriteString((CHAR*)"(void*)", 8);
}
} else {
if ((__IN(form, 0x0180) && __IN(n->typ->form, 0x70))) {
if ((__IN(form, 0x0180) && n->typ->form == 5)) {
OPM_WriteString((CHAR*)"(double)", 9);
prec = 9;
} else if (__IN(form, 0x70)) {
} else if (form == 5) {
OPV_SizeCast(n->typ->size, typ->size);
}
}
@ -812,7 +812,7 @@ static void OPV_ActualPar (OPT_Node n, OPT_Object fp)
}
if ((((mode == 2 && n->class == 11)) && n->subcl == 29)) {
OPV_expr(n->left, prec);
} else if ((__IN(form, 0x70) && n->class == 7)) {
} else if ((form == 5 && n->class == 7)) {
OPV_ParIntLiteral(n->conval->intval, n->typ->size);
} else {
OPV_expr(n, prec);
@ -966,7 +966,7 @@ static void OPV_expr (OPT_Node n, INTEGER prec)
}
break;
case 29:
if (!__IN(l->class, 0x17) || (((__IN(n->typ->form, 0x6240) && __IN(l->typ->form, 0x6240))) && n->typ->size == l->typ->size)) {
if (!__IN(l->class, 0x17) || (((__IN(n->typ->form, 0x6220) && __IN(l->typ->form, 0x6220))) && n->typ->size == l->typ->size)) {
OPM_Write('(');
OPC_Ident(n->typ->strobj);
OPM_Write(')');
@ -1116,7 +1116,7 @@ static void OPV_expr (OPT_Node n, INTEGER prec)
OPM_WriteString((CHAR*)" ^ ", 4);
} else {
OPM_WriteString((CHAR*)" / ", 4);
if (r->obj == NIL || __IN(r->obj->typ->form, 0x70)) {
if (r->obj == NIL || r->obj->typ->form == 5) {
OPM_Write('(');
OPC_Ident(n->typ->strobj);
OPM_Write(')');