Activity for BCMath Library for JavaScript

  • Rob Rob created ticket #5

    Fix for truncated instead of rounded results

  • Rob Rob posted a comment on ticket #4

    I just noticed that there will be more "undefined property" warnings if no decimal point is used, i.e. when multiplying 10 and 10 instead of 10.0 and 10.0 ... the following snippet takes care of everything, including the original issue mentioned above, replace lines 144 - 157 with this: //while (bcmath.isdigit(str[ptr])) while((ptr<str.length) && ((str[ptr]) % 1 === 0)) { //bcmath.isdigit(str[ptr])) { ptr++; digits++; /* digits */ } if((ptr<str.length) && (str[ptr] === '.')) { ptr++; /* decimal point...

  • Rob Rob posted a comment on ticket #4

    Of course, the ptr then doesn't have to be incremented inside the loop anymore. for(;ptr < str.length;++ptr) { //bcmath.isdigit(str[ptr])) { //ptr++; strscale++; /* digits */ }

  • Rob Rob created ticket #4

    Fix for Undefined Property warning

1
MongoDB Logo MongoDB