diff --git a/src/arithops.c b/src/arithops.c index 9bee65e..90faa30 100644 --- a/src/arithops.c +++ b/src/arithops.c @@ -313,7 +313,7 @@ LispPTR N_OP_makenumber(LispPTR tosm1, LispPTR tos) { if (((tosm1 & 0xFFFF0000) != S_POSITIVE) || ((tos & 0xFFFF0000) != S_POSITIVE)) ERROR_EXIT(tos); /* UB: left shift of 49152 by 16 places cannot be represented in type 'int' */ - result = ((tosm1 & 0xffff) << 16) | (tos & 0xffff); + result = (int)(((tosm1 & 0xffff) << 16) | (tos & 0xffff)); N_ARITH_SWITCH(result); } /* end OP_makenumber */