From 8c8078513e60df7e017f91193524384e4e9640ca Mon Sep 17 00:00:00 2001 From: dimenus Date: Fri, 8 Nov 2019 18:16:03 -0600 Subject: [PATCH] missed cast in std/target.zig --- lib/std/target.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/std/target.zig b/lib/std/target.zig index d84ef47347..4d600d4d38 100644 --- a/lib/std/target.zig +++ b/lib/std/target.zig @@ -319,7 +319,7 @@ pub const Target = union(enum) { inline for (info.Union.fields) |field| { if (mem.eql(u8, text, field.name)) { if (field.field_type == void) { - return (Arch)(@field(Arch, field.name)); + return @as(Arch, @field(Arch, field.name)); } else { const sub_info = @typeInfo(field.field_type); inline for (sub_info.Enum.fields) |sub_field| { @@ -581,7 +581,7 @@ pub const Target = union(enum) { }; pub fn getExternalExecutor(self: Target) Executor { - if (@as(@TagType(Target),self) == .Native) return .native; + if (@as(@TagType(Target), self) == .Native) return .native; // If the target OS matches the host OS, we can use QEMU to emulate a foreign architecture. if (self.getOs() == builtin.os) {