Small optimization for ftostr43

master
Scott Lahteine 9 years ago
parent a393941d2d
commit b98f72b483

@ -2228,11 +2228,11 @@ char* ftostr43(const float& x) {
long xx = x * 1000; long xx = x * 1000;
char *conv_ptr = conv; char *conv_ptr = conv;
if (xx >= 0) { if (xx >= 0) {
*conv_ptr++ = ' '; conv_ptr++;
} }
else { else {
conv[0] = '-';
xx = -xx; xx = -xx;
conv[0] = '-';
} }
conv[1] = (xx / 1000) % 10 + '0'; conv[1] = (xx / 1000) % 10 + '0';
conv[2] = '.'; conv[2] = '.';

Loading…
Cancel
Save