[Rawstudio-dev] [PATCH] Fix non optimizedgreenish tint loading

Edouard Gomez ed.gomez at free.fr
Wed Sep 27 00:13:54 CEST 2006

Soren Hansen (sh at warma.dk) wrote:
> I DO know that:
> 		b = (src[srcoffset+=2] - raw->black)<<shift;
> Is not equivalent to:
> 		b = (src[srcoffset++] - raw->black)<<shift;
> 		srcoffset++;

I never meant to make it equivalent. I meant to revert the behavior as
the previous cset, keeping the core of the fix contained in the buggy
cset :-)

To sum up thing, "a++" is a postfixed operation, it's evaluated after the use
of "a" whereas "a +=" is a prefixed operation, a is first evaluated and
then used.

We all agree on that :-) At least, that's what my dusty C book tells me.

Edouard Gomez

More information about the Rawstudio-dev mailing list