Build: fix warnings. Fixes #1653.
authorJohn Kessenich <cepheus@frii.com>
Wed, 16 Jan 2019 07:55:37 +0000 (14:55 +0700)
committerJohn Kessenich <cepheus@frii.com>
Wed, 16 Jan 2019 07:55:37 +0000 (14:55 +0700)
SPIRV/GlslangToSpv.cpp [changed mode: 0644->0755]
glslang/MachineIndependent/ParseHelper.cpp

old mode 100644 (file)
new mode 100755 (executable)
index c7cab84..9bf3704
@@ -3232,7 +3232,7 @@ spv::Id TGlslangToSpvTraverser::convertGlslangStructToSpvType(const glslang::TTy
     // Decorate it
     decorateStructType(type, glslangMembers, explicitLayout, qualifier, spvType);
 
-    for (int i = 0; i < deferredForwardPointers.size(); ++i) {
+    for (int i = 0; i < (int)deferredForwardPointers.size(); ++i) {
         auto it = deferredForwardPointers[i];
         convertGlslangToSpvType(*it.first, explicitLayout, it.second, false);
     }
index d16dc99..128fd7a 100755 (executable)
@@ -5062,7 +5062,7 @@ void TParseContext::setLayoutQualifier(const TSourceLoc& loc, TPublicType& publi
         if (! IsPow2(value))
             error(loc, "must be a power of 2", "buffer_reference_align", "");
         else
-            publicType.qualifier.layoutBufferReferenceAlign = std::log2(value);
+            publicType.qualifier.layoutBufferReferenceAlign = (unsigned int)std::log2(value);
         return;
     }