diff options
| author | antlilja <liljaanton2001@gmail.com> | 2020-06-17 18:18:45 +0200 |
|---|---|---|
| committer | antlilja <liljaanton2001@gmail.com> | 2020-06-17 18:18:45 +0200 |
| commit | eb7fad28f8f11b985c8ee6fbeb4a68345a9b3a5e (patch) | |
| tree | 078b19ddf21e6d3901ff614d87a03b48c2a5315c /lib/std/math.zig | |
| parent | 1157ee130732449811294d70021aaafa588d3048 (diff) | |
| download | zig-eb7fad28f8f11b985c8ee6fbeb4a68345a9b3a5e.tar.gz zig-eb7fad28f8f11b985c8ee6fbeb4a68345a9b3a5e.zip | |
Improve f128 standard library support
* Add functions: floor128, ceil128, trunc128 and round128
* Add corresponding tests
Diffstat (limited to 'lib/std/math.zig')
| -rw-r--r-- | lib/std/math.zig | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/std/math.zig b/lib/std/math.zig index 5cf6d40d8a..799c42846b 100644 --- a/lib/std/math.zig +++ b/lib/std/math.zig @@ -122,6 +122,11 @@ pub fn forceEval(value: var) void { const p = @ptrCast(*volatile f64, &x); p.* = x; }, + f128 => { + var x: f128 = undefined; + const p = @ptrCast(*volatile f128, &x); + p.* = x; + }, else => { @compileError("forceEval not implemented for " ++ @typeName(T)); }, |
