diff --git a/extracted/plugins/B2DPlugin/src/common/B2DPlugin.c b/extracted/plugins/B2DPlugin/src/common/B2DPlugin.c index 575585d108..5261feff4e 100644 --- a/extracted/plugins/B2DPlugin/src/common/B2DPlugin.c +++ b/extracted/plugins/B2DPlugin/src/common/B2DPlugin.c @@ -13643,6 +13643,7 @@ stepToNextWideBezierInat(sqInt bezier, sqInt yValue) updateData[GBUpdateY] = lastY; updateData[GBUpdateDX] = fwDx; updateData[GBUpdateDY] = fwDy; + ((signed)lastX >> 8); } else { @@ -13672,6 +13673,7 @@ stepToNextWideBezierInat(sqInt bezier, sqInt yValue) updateData1[GBUpdateY] = lastY1; updateData1[GBUpdateDX] = fwDx1; updateData1[GBUpdateDY] = fwDy1; + ((signed)lastX1 >> 8); computeFinalWideBezierValueswidth(bezier, lineWidth); return 0; } diff --git a/extracted/plugins/JPEGReadWriter2Plugin/src/common/jdphuff.c b/extracted/plugins/JPEGReadWriter2Plugin/src/common/jdphuff.c index 2267809945..892ee527ce 100755 --- a/extracted/plugins/JPEGReadWriter2Plugin/src/common/jdphuff.c +++ b/extracted/plugins/JPEGReadWriter2Plugin/src/common/jdphuff.c @@ -200,7 +200,7 @@ start_pass_phuff_decoder (j_decompress_ptr cinfo) #ifdef AVOID_TABLES -#define HUFF_EXTEND(x,s) ((x) < (1<<((s)-1)) ? (x) + (((-1)<<(s)) + 1) : (x)) +#define HUFF_EXTEND(x,s) ((x) < (1<<((s)-1)) ? (x) + ((((signed int)((unsigned int)-1))<<(s)) + 1) : (x)) #else @@ -211,10 +211,10 @@ static const int extend_test[16] = /* entry n is 2**(n-1) */ 0x0100, 0x0200, 0x0400, 0x0800, 0x1000, 0x2000, 0x4000 }; static const int extend_offset[16] = /* entry n is (-1 << n) + 1 */ - { 0, ((-1)<<1) + 1, ((-1)<<2) + 1, ((-1)<<3) + 1, ((-1)<<4) + 1, - ((-1)<<5) + 1, ((-1)<<6) + 1, ((-1)<<7) + 1, ((-1)<<8) + 1, - ((-1)<<9) + 1, ((-1)<<10) + 1, ((-1)<<11) + 1, ((-1)<<12) + 1, - ((-1)<<13) + 1, ((-1)<<14) + 1, ((-1)<<15) + 1 }; + { 0, (((signed int)((unsigned int)-1))<<1) + 1, (((signed int)((unsigned int)-1))<<2) + 1, (((signed int)((unsigned int)-1))<<3) + 1, (((signed int)((unsigned int)-1))<<4) + 1, + (((signed int)((unsigned int)-1))<<5) + 1, (((signed int)((unsigned int)-1))<<6) + 1, (((signed int)((unsigned int)-1))<<7) + 1, (((signed int)((unsigned int)-1))<<8) + 1, + (((signed int)((unsigned int)-1))<<9) + 1, (((signed int)((unsigned int)-1))<<10) + 1, (((signed int)((unsigned int)-1))<<11) + 1, (((signed int)((unsigned int)-1))<<12) + 1, + (((signed int)((unsigned int)-1))<<13) + 1, (((signed int)((unsigned int)-1))<<14) + 1, (((signed int)((unsigned int)-1))<<15) + 1 }; #endif /* AVOID_TABLES */ @@ -493,7 +493,7 @@ decode_mcu_AC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data) phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy; int Se = cinfo->Se; int p1 = 1 << cinfo->Al; /* 1 in the bit position being coded */ - int m1 = (-1) << cinfo->Al; /* -1 in the bit position being coded */ + int m1 = ((signed int)((unsigned int)-1)) << cinfo->Al; /* -1 in the bit position being coded */ register int s, k, r; unsigned int EOBRUN; JBLOCKROW block; diff --git a/extracted/plugins/UnixOSProcessPlugin/src/common/UnixOSProcessPlugin.c b/extracted/plugins/UnixOSProcessPlugin/src/common/UnixOSProcessPlugin.c index db3b4417ea..2e22dd9d65 100644 --- a/extracted/plugins/UnixOSProcessPlugin/src/common/UnixOSProcessPlugin.c +++ b/extracted/plugins/UnixOSProcessPlugin/src/common/UnixOSProcessPlugin.c @@ -281,7 +281,7 @@ static sqInt (*popthenPush)(sqInt nItems, sqInt oop); static sqInt (*popRemappableOop)(void); static sqInt (*primitiveFail)(void); static sqInt (*primitiveFailFor)(sqInt reasonCode); -static sqInt (*push)(sqInt object); +static (*push)(sqInt object); static sqInt (*pushInteger)(sqInt integerValue); static sqInt (*pushRemappableOop)(sqInt oop); static sqInt (*signalSemaphoreWithIndex)(sqInt semaIndex); diff --git a/extracted/vm/include/common/sqVirtualMachine.h b/extracted/vm/include/common/sqVirtualMachine.h index c18bb63a19..214ce74f34 100644 --- a/extracted/vm/include/common/sqVirtualMachine.h +++ b/extracted/vm/include/common/sqVirtualMachine.h @@ -6,6 +6,7 @@ */ #include "interp.h" + #if SPURVM # define VM_VERSION "5.0" #else @@ -62,9 +63,9 @@ typedef struct VirtualMachine { sqInt (*pop)(sqInt nItems); sqInt (*popthenPush)(sqInt nItems, sqInt oop); - sqInt (*push)(sqInt object); + void (*push)(sqInt object); sqInt (*pushBool)(sqInt trueOrFalse); - sqInt (*pushFloat)(double f); + void (*pushFloat)(double f); sqInt (*pushInteger)(sqInt integerValue); double (*stackFloatValue)(sqInt offset); sqInt (*stackIntegerValue)(sqInt offset); @@ -171,7 +172,7 @@ typedef struct VirtualMachine { # if VM_PROXY_MINOR > 13 /* Reuse these now that Cog provides a production JIT. */ sqInt (*statNumGCs)(void); - sqInt (*stringForCString)(char *nullTerminatedCString); + sqInt (*stringForCString)(const char *nullTerminatedCString); # else /* InterpreterProxy methodsFor: 'compiler' */ @@ -201,7 +202,7 @@ typedef struct VirtualMachine { sqInt (*classExternalAddress)(void); void *(*ioLoadModuleOfLength)(sqInt modIndex, sqInt modLength); - void *(*ioLoadSymbolOfLengthFromModule)(sqInt fnIndex, sqInt fnLength, sqInt handle); + void *(*ioLoadSymbolOfLengthFromModule)(sqInt fnIndex, sqInt fnLength, void* handle); sqInt (*isInMemory)(sqInt address); #endif @@ -234,7 +235,7 @@ typedef struct VirtualMachine { #if VM_PROXY_MINOR > 5 sqInt (*isArray)(sqInt oop); - void (*forceInterruptCheck)(void); + sqInt (*forceInterruptCheck)(void); #endif #if VM_PROXY_MINOR > 6 @@ -291,7 +292,7 @@ typedef struct VirtualMachine { #if VM_PROXY_MINOR > 10 void (*addHighPriorityTickee)(void (*ticker)(void), unsigned periodms); void (*addSynchronousTickee)(void (*ticker)(void), unsigned periodms, unsigned roundms); - volatile usqLong (*utcMicroseconds)(void); + volatile unsigned long long (*utcMicroseconds)(void); void (*tenuringIncrementalGC)(void); sqInt (*isYoung) (sqInt anOop); sqInt (*isKindOfClass)(sqInt oop, sqInt aClass); @@ -338,7 +339,7 @@ typedef struct VirtualMachine { sqInt (*scheduleInMainThread)(sqInt (*closure)()); - sqInt (*waitOnExternalSemaphoreIndex)(sqInt semaphoreIndex); + void (*waitOnExternalSemaphoreIndex)(sqInt semaphoreIndex); } VirtualMachine;