Big integer, Big float, and operator overloading ideas

Fabrice Bellard fabrice at bellard.org
Fri Mar 16 12:25:18 UTC 2018


Hi,

I have designed a Javascript extension which supports big integers, big 
floats and operator overloading. It is not 100% compatible with 
Javascript because I wanted no distinction between legacy javascript 
numbers and big integers or big floats, but most of the language 
semantics are preserved. I guess some ideas may be useful for a 100% 
compatible behavior, in particular for the operator overloading.

I published a summary of the changes at http://numcalc.com/jsbignum.pdf 
. A preliminary implementation running a numerical calculator is 
available at http://numcalc.com . The source code of the calculator ( 
http://numcalc.com/jscalc.js ) shows how the bignum extensions can be 
used to easily manipulate fractions, complex numbers, polynomials and 
matrixes.

Fabrice.


More information about the es-discuss mailing list