Commit 1a492d5156

Andrew Kelley <andrew@ziglang.org>
2021-09-01 04:19:35
re-apply a commit dropped in this branch due to conflicts
This commit reapplies 4f0aa7d639e099b18df583cb984412037fbb1dbe.
1 parent 5a4cc24
Changed files (3)
lib/std/c/dragonfly.zig
@@ -204,7 +204,7 @@ pub const W = struct {
         return TERMSIG(s) == 0;
     }
     pub fn IFSTOPPED(s: u32) bool {
-        return @intCast(u16, (((s & 0xffff) *% 0x10001) >> 8)) > 0x7f00;
+        return @truncate(u16, (((s & 0xffff) *% 0x10001) >> 8)) > 0x7f00;
     }
     pub fn IFSIGNALED(s: u32) bool {
         return (s & 0xffff) -% 1 < 0xff;
lib/std/c/freebsd.zig
@@ -431,7 +431,7 @@ pub const W = struct {
         return TERMSIG(s) == 0;
     }
     pub fn IFSTOPPED(s: u32) bool {
-        return @intCast(u16, (((s & 0xffff) *% 0x10001) >> 8)) > 0x7f00;
+        return @truncate(u16, (((s & 0xffff) *% 0x10001) >> 8)) > 0x7f00;
     }
     pub fn IFSIGNALED(s: u32) bool {
         return (s & 0xffff) -% 1 < 0xff;
lib/std/os/linux.zig
@@ -1788,7 +1788,7 @@ pub const W = struct {
         return TERMSIG(s) == 0;
     }
     pub fn IFSTOPPED(s: u32) bool {
-        return @intCast(u16, ((s & 0xffff) *% 0x10001) >> 8) > 0x7f00;
+        return @truncate(u16, ((s & 0xffff) *% 0x10001) >> 8) > 0x7f00;
     }
     pub fn IFSIGNALED(s: u32) bool {
         return (s & 0xffff) -% 1 < 0xff;