diff options
| author | Jacob Young <jacobly0@users.noreply.github.com> | 2023-08-06 00:17:37 -0400 |
|---|---|---|
| committer | Jacob Young <jacobly0@users.noreply.github.com> | 2023-08-06 00:35:10 -0400 |
| commit | 1cce539ddcba1e21615e11dcf75f011074942414 (patch) | |
| tree | 2e7b979cbfcf9b7c3597f5094184a0bdcdf27214 /src/codegen | |
| parent | 7dacf7774523a454fce7216c13eb03c6badf8d7b (diff) | |
| download | zig-1cce539ddcba1e21615e11dcf75f011074942414.tar.gz zig-1cce539ddcba1e21615e11dcf75f011074942414.zip | |
json.stringify: properly implement RFC8259 recommendation
The previous magic numbers used `1 << 52`, which did not account for the
implicit leading one in the floating point format. The RFC is correct
when it uses an exponent of 53. Technically these exclusive endpoints
are also representable, but everyone including the RFC seems to use them
exclusively.
Also, delete special case optimizations related to the type which have
already been implemented in the zig compiler to produce comptime values
for tautological runtime comparisons.
Diffstat (limited to 'src/codegen')
0 files changed, 0 insertions, 0 deletions
