Browse Source

Merge pull request #90 from FrankBoesing/patch-4

use float version of fcvt
main
Paul Stoffregen 8 years ago
parent
commit
1e1b43ca7d
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      teensy3/nonstd.c

+ 1
- 1
teensy3/nonstd.c View File

const char *s, *e; const char *s, *e;
char *p; char *p;


s = fcvt(val, precision, &decpt, &sign);
s = fcvtf(val, precision, &decpt, &sign);
if (precision == 0 && decpt == 0) { if (precision == 0 && decpt == 0) {
s = (*s < '5') ? "0" : "1"; s = (*s < '5') ? "0" : "1";
reqd = 1; reqd = 1;

Loading…
Cancel
Save