From 41fc4c55c6b8693afbaa9babb5cf71fce97535f4 Mon Sep 17 00:00:00 2001 From: Ekopalypse <47723516+Ekopalypse@users.noreply.github.com> Date: Tue, 14 Sep 2021 16:47:26 +0200 Subject: [PATCH] v.builder: simplify target architecture logic for msvc (#11491) --- vlib/v/builder/msvc.v | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/vlib/v/builder/msvc.v b/vlib/v/builder/msvc.v index 903c0fb623..a84c14829e 100644 --- a/vlib/v/builder/msvc.v +++ b/vlib/v/builder/msvc.v @@ -237,16 +237,7 @@ fn find_msvc(m64_target bool) ?MsvcResult { '%ProgramFiles(x86)%' } host_arch := if processor_architecture == 'x86' { 'X86' } else { 'X64' } - mut target_arch := 'X64' - if host_arch == 'X86' { - if !m64_target { - target_arch = 'X86' - } - } else if host_arch == 'X64' { - if !m64_target { - target_arch = 'X86' - } - } + target_arch := if !m64_target { 'X86' } else { 'X64' } wk := find_windows_kit_root(target_arch) or { return error('Unable to find windows sdk') } vs := find_vs(vswhere_dir, host_arch, target_arch) or { return error('Unable to find visual studio')