Several fixes to make glslang compile with higher warning levels.

This commit is contained in:
2022-12-08 21:31:51 +01:00
parent be564292f0
commit 8f0a4c64db
8 changed files with 58 additions and 22 deletions

View File

@@ -181,6 +181,7 @@ void Builder::postProcessType(const Instruction& inst, Id typeId)
else if (width == 8)
addCapability(CapabilityInt8);
}
[[fallthrough]]; // @MEWIN - 2022-12-07 - Added this to get rid of implicit-fallthrough warning.
default:
if (basicTypeOp == OpTypeInt) {
if (width == 16)

View File

@@ -240,8 +240,8 @@ public:
OperandParameters operands;
protected:
int typePresent : 1;
int resultPresent : 1;
unsigned typePresent : 1; // @MEWIN - 2022-12-07 - Changed to unsigned to get rid of -Woverflow warnings.
unsigned resultPresent : 1; // @MEWIN - 2022-12-07 - Changed to unsigned to get rid of -Woverflow warnings.
};
// The set of objects that hold all the instruction/operand