aboutsummaryrefslogtreecommitdiff
path: root/lib/std/math/float.zig
AgeCommit message (Collapse)Author
2022-08-22Sema: fix parameter of type 'T' must be comptime errorVeikka Tuominen
Closes #12519 Closes #12505
2022-07-13stage2: fix comptime bitcast involving f80Andrew Kelley
* Sema: implement comptime bitcast of f80 with integer-like types bitwise rather than taking a round trip through memory layout. * Type: introduce `isAbiInt`. * Value: comptime memory write of f80 writes 0 bytes for padding instead of leaving the memory uninitialized. * Value: floatReadFromMemory has a more general implementation, checking the endianness rather than checking for specific architectures. This fixes behavior test failures occurring on MIPS.
2022-07-13std.math: add `inline` to some functionsAndrew Kelley
These functions semantically benefit from being inline; it makes sense that `isInf(x)` where `x` is comptime-known should have a comptime-known result.
2022-04-14std.math.float: fix f80-backed c_longdouble constsvi
2022-04-12Add `floatFractionalBits` to replace `floatMantissaDigits`Cody Tapscott
2022-04-07std.math: generalise `inf`, even simpler `isFinite`viri
2022-04-06derive float constants in a generic way (#10133)viri