Fix -Wignored-qualifier and -Wunused-variable warnings
authorCorentin Wallez <cwallez@chromium.org>
Wed, 8 Aug 2018 13:20:15 +0000 (15:20 +0200)
committerCorentin Wallez <cwallez@chromium.org>
Thu, 9 Aug 2018 12:54:33 +0000 (14:54 +0200)
SPIRV/GlslangToSpv.cpp
glslang/MachineIndependent/reflection.h

index c3e7940..5032cc1 100755 (executable)
@@ -5383,8 +5383,10 @@ spv::Id TGlslangToSpvTraverser::createAtomicOperation(glslang::TOperator op, spv
 // Create group invocation operations.
 spv::Id TGlslangToSpvTraverser::createInvocationsOperation(glslang::TOperator op, spv::Id typeId, std::vector<spv::Id>& operands, glslang::TBasicType typeProxy)
 {
+#ifdef AMD_EXTENSIONS
     bool isUnsigned = isTypeUnsignedInt(typeProxy);
     bool isFloat = isTypeFloat(typeProxy);
+#endif
 
     spv::Op opCode = spv::OpNop;
     std::vector<spv::Id> spvGroupOperands;
index 2cd14df..49282c3 100644 (file)
@@ -59,7 +59,7 @@ public:
         name(pName), offset(pOffset),
         glDefineType(pGLDefineType), size(pSize), index(pIndex), counterIndex(-1), stages(EShLanguageMask(0)), type(pType.clone()) { }
 
-    const TType* const getType() const { return type; }
+    const TType* getType() const { return type; }
     int getBinding() const
     {
         if (type == nullptr || !type->getQualifier().hasBinding())