Skip to content

Commit

Permalink
Merge pull request #1459 from dgkoch/dgkoch_build_fixes4
Browse files Browse the repository at this point in the history
Fix various build warnings/errors
  • Loading branch information
johnkslang authored Aug 1, 2018
2 parents e99a268 + 883607d commit 29619b2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions glslang/MachineIndependent/Constant.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ TIntermTyped* TIntermConstantUnion::fold(TOperator op, const TIntermTyped* right
else if (leftUnionArray[i].getDConst() > 0.0)
newConstArray[i].setDConst((double)INFINITY);
else if (leftUnionArray[i].getDConst() < 0.0)
newConstArray[i].setDConst((double)-INFINITY);
newConstArray[i].setDConst(-(double)INFINITY);
else
newConstArray[i].setDConst((double)NAN);
break;
Expand Down Expand Up @@ -223,8 +223,8 @@ TIntermTyped* TIntermConstantUnion::fold(TOperator op, const TIntermTyped* right
case EbtInt:
if (rightUnionArray[i] == 0)
newConstArray[i].setIConst(0x7FFFFFFF);
else if (rightUnionArray[i].getIConst() == -1 && leftUnionArray[i].getIConst() == -(int)0x80000000)
newConstArray[i].setIConst(-(int)0x80000000);
else if (rightUnionArray[i].getIConst() == -1 && leftUnionArray[i].getIConst() == (int)-0x80000000ll)
newConstArray[i].setIConst((int)-0x80000000ll);
else
newConstArray[i].setIConst(leftUnionArray[i].getIConst() / rightUnionArray[i].getIConst());
break;
Expand All @@ -239,8 +239,8 @@ TIntermTyped* TIntermConstantUnion::fold(TOperator op, const TIntermTyped* right
case EbtInt64:
if (rightUnionArray[i] == 0ll)
newConstArray[i].setI64Const(0x7FFFFFFFFFFFFFFFll);
else if (rightUnionArray[i].getI64Const() == -1 && leftUnionArray[i].getI64Const() == -0x8000000000000000ll)
newConstArray[i].setI64Const(-0x8000000000000000ll);
else if (rightUnionArray[i].getI64Const() == -1 && leftUnionArray[i].getI64Const() == (long long)-0x8000000000000000ll)
newConstArray[i].setI64Const((long long)-0x8000000000000000ll);
else
newConstArray[i].setI64Const(leftUnionArray[i].getI64Const() / rightUnionArray[i].getI64Const());
break;
Expand Down
2 changes: 1 addition & 1 deletion glslang/MachineIndependent/reflection.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class TObjectReflection {
public:
TObjectReflection(const TString& pName, const TType& pType, int pOffset, int pGLDefineType, int pSize, int pIndex) :
name(pName), offset(pOffset),
glDefineType(pGLDefineType), size(pSize), index(pIndex), counterIndex(-1), type(pType.clone()), stages(EShLanguageMask(0)) { }
glDefineType(pGLDefineType), size(pSize), index(pIndex), counterIndex(-1), stages(EShLanguageMask(0)), type(pType.clone()) { }

const TType* const getType() const { return type; }
int getBinding() const
Expand Down

0 comments on commit 29619b2

Please sign in to comment.