Skip to content

Commit

Permalink
Fix type inference of unskew variable in BitBltPlugin
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-cellier-aka-nice committed Nov 24, 2017
1 parent 834da78 commit 0cf8303
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions src/plugins/BitBltPlugin/BitBltPlugin.c
@@ -1,9 +1,9 @@
/* Automatically generated by
SmartSyntaxPluginCodeGenerator VMMaker.oscog-eem.2278 uuid: 4fd41cee-a3bd-48f4-b02e-cf367a331eec
SmartSyntaxPluginCodeGenerator VMMaker.oscog- nice.2281 uuid: 4beeaee7-567e-1a4b-b0fb-bd95ce302516
from
BitBltSimulation VMMaker.oscog-eem.2278 uuid: 4fd41cee-a3bd-48f4-b02e-cf367a331eec
BitBltSimulation VMMaker.oscog- nice.2281 uuid: 4beeaee7-567e-1a4b-b0fb-bd95ce302516
*/
static char __buildInfo[] = "BitBltSimulation VMMaker.oscog-eem.2278 uuid: 4fd41cee-a3bd-48f4-b02e-cf367a331eec " __DATE__ ;
static char __buildInfo[] = "BitBltSimulation VMMaker.oscog- nice.2281 uuid: 4beeaee7-567e-1a4b-b0fb-bd95ce302516 " __DATE__ ;



Expand Down Expand Up @@ -352,9 +352,9 @@ static int maskTable[33] = {
};
static const char *moduleName =
#ifdef SQUEAK_BUILTIN_PLUGIN
"BitBltPlugin VMMaker.oscog-eem.2278 (i)"
"BitBltPlugin VMMaker.oscog- nice.2281 (i)"
#else
"BitBltPlugin VMMaker.oscog-eem.2278 (e)"
"BitBltPlugin VMMaker.oscog- nice.2281 (e)"
#endif
;
static sqInt noHalftone;
Expand Down Expand Up @@ -1969,7 +1969,7 @@ copyLoop(void)
unsigned int skewMask;
unsigned int skewWord;
unsigned int thisWord;
unsigned int unskew;
sqInt unskew;
sqInt word;
int y;

Expand All @@ -1979,7 +1979,11 @@ copyLoop(void)
/* degenerate skew fixed for Sparc. 10/20/96 ikp */
hInc = hDir * 4;
if (skew == -32) {
skew = (unskew = (skewMask = 0));

/* Beware: separate skewMask initialization to avoid bad type inference.
Indeed, unskew is a bitShift and MUST remain signed, while skewMask is unsigned */
skew = (unskew = 0);
skewMask = 0;
}
else {
if (skew < 0) {
Expand Down

0 comments on commit 0cf8303

Please sign in to comment.