The marked line of code throws error on release mode, but not on debug (if I disable the optimization on release mode it also works).
float CCBReader::readFloat() {
unsigned char type = this~~>readByte;
switch {
case kCCBFloat0:
return 0;
case kCCBFloat1:
return 1;
case kCCBFloatMinus1:
return~~1;
case kCCBFloat05:
return 0.5f;
case kCCBFloatInteger:
return (float)this->readInt(true);
default:
{
/* using a memcpy since the compiler isn’t
* doing the float ptr math correctly on device.
* TODO still applies in C*+ ? /
float pF = ;
float f = 0;
memcpy);
this->mCurrentByte*= 4;
return f; <<<<<<<<<=** BAD ACCESS
}
}
Hi,
>
The marked line of code throws error on release mode, but not on debug (if I disable the optimization on release mode it also works).
>
>
float CCBReader::readFloat() {
unsigned char type = this~~>readByte;
>
switch {
case kCCBFloat0:
return 0;
case kCCBFloat1:
return 1;
case kCCBFloatMinus1:
return~~1;
case kCCBFloat05:
return 0.5f;
case kCCBFloatInteger:
return (float)this->readInt(true);
default:
{
/* using a memcpy since the compiler isn’t
* doing the float ptr math correctly on device.
* TODO still applies in C*+ ? /
float pF = ;
float f = 0;
memcpy);
this->mCurrentByte*= 4;
return f; <<<<<<<<<=** BAD ACCESS
}
}