🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Angelscript 2.5.0a Unit Tests

Started by
20 comments, last by pratty 18 years, 4 months ago
Just a nitpick, but it's rather silly to use the FPU for something like:
123 Allocate(int(maxLength*1.5f) + 1, true);

when this would be just as good:

Allocate(maxLength + (maxLength>>1) + 1, true);

When you only deal with integers, it's good to not involve floating point unless necessary.
Advertisement
WitchLord,

You're right, the example:

double var = 30;

should really have been:

const double var = 30;


As for the 2nd example, I'll see if I can trace back through the scripts where I noticed the inconsistent behaviour.

cheers
Pratty

This topic is closed to new replies.

Advertisement