From 04a2fe93d064385a81cd8b2ae5312448e016916a Mon Sep 17 00:00:00 2001 From: Corentin Wallez Date: Mon, 29 Oct 2018 16:24:00 +0100 Subject: [PATCH] Fix MSVC warning C4065: 'default' but no 'case' labels This would happen in SpvPostProcess when we don't enable AMD extensions. --- SPIRV/SpvPostProcess.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SPIRV/SpvPostProcess.cpp b/SPIRV/SpvPostProcess.cpp index 27f145d0..653edf42 100755 --- a/SPIRV/SpvPostProcess.cpp +++ b/SPIRV/SpvPostProcess.cpp @@ -121,8 +121,8 @@ void Builder::postProcessType(const Instruction& inst, Id typeId) case OpUConvert: break; case OpExtInst: - switch (inst.getImmediateOperand(1)) { #if AMD_EXTENSIONS + switch (inst.getImmediateOperand(1)) { case GLSLstd450Frexp: case GLSLstd450FrexpStruct: if (getSpvVersion() < glslang::EShTargetSpv_1_3 && containsType(typeId, OpTypeInt, 16)) @@ -134,10 +134,10 @@ void Builder::postProcessType(const Instruction& inst, Id typeId) if (getSpvVersion() < glslang::EShTargetSpv_1_3 && containsType(typeId, OpTypeFloat, 16)) addExtension(spv::E_SPV_AMD_gpu_shader_half_float); break; -#endif default: break; } +#endif break; default: if (basicTypeOp == OpTypeFloat && width == 16)