Hacker News new | ask | show | jobs
by thinkredstone 1031 days ago
Like I wrote in the article, the engine uses `rust_decimal` to represent arbitrary precision floating point numbers- this is how the engine supports SQL types likes postgres's `decimal`.

We support using ieee754 floating point numbers as well, but those have no special serialization requirements- the structure of a ieee754 floating-point number was designed so that lexicographical comparisons and numeric comparisons give the same results (I took inspiration from that to write the serialization code that solves the issue, which I'll lay out sometime when I write part 2 of this story).