Fix ethMD5 build. May need more work to be correct on 64 bit builds.

This commit is contained in:
David Brown 2016-09-20 16:43:34 +01:00
parent 9971e56451
commit 1a83167d5a
200 changed files with 407 additions and 372 deletions

View file

@ -1,4 +1,4 @@
/* voc 1.95 [2016/09/18] for gcc LP64 on cygwin xtspkaSfF */
/* voc 1.95 [2016/09/20] for gcc LP64 on cygwin xtspkaSfF */
#define INTEGER int16
#define LONGINT int32
@ -139,6 +139,7 @@ export void OPT_Init (OPS_Name name, SET opt);
static void OPT_InitStruct (OPT_Struct *typ, int8 form);
export void OPT_Insert (OPS_Name name, OPT_Object *obj);
export void OPT_InsertImport (OPT_Object obj, OPT_Object *root, OPT_Object *old);
export int16 OPT_IntSize (int64 n);
export OPT_Struct OPT_IntType (int32 size);
export OPT_Const OPT_NewConst (void);
export OPT_ConstExt OPT_NewExt (void);
@ -164,6 +165,21 @@ static void OPT_err (int16 n)
OPM_err(n);
}
int16 OPT_IntSize (int64 n)
{
int16 _o_result;
int16 bytes;
if (n < 0) {
n = -(n + 1);
}
bytes = 1;
while ((bytes < 8 && __ASH(n, -(__ASHL(bytes, 3) - 1)) != 0)) {
bytes += 1;
}
_o_result = bytes;
return _o_result;
}
OPT_Struct OPT_IntType (int32 size)
{
OPT_Struct _o_result;