I want a class for representing and manipulating a 128-bit decimal data type, a quadruple-precision floating point. I found double.js, but it supports only 106 accurate bits (double-double). I'm looking for something like .NET's Decimal
data type or something following Wikipedia.
I also need the class to have a method that returns its composing bytes, like toBytes()
, which returns an array of bytes (16 bytes). Also tell me in which endianness they're returned.