Merge pull request #1166 from tafuri/#1165-invalid_Store

#1165 invalid store
This commit is contained in:
John Kessenich 2017-11-28 19:41:52 -07:00 committed by GitHub
commit 1ce94b2d68
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 1099 additions and 890 deletions

View file

@ -3274,6 +3274,9 @@ void HlslParseContext::decomposeStructBufferMethods(const TSourceLoc& loc, TInte
: EOpIndexIndirect;
TIntermTyped* lValue = intermediate.addIndex(idxOp, argArray, offsetIdx, loc);
const TType derefType(argArray->getType(), 0);
lValue->setType(derefType);
TIntermTyped* rValue = (size == 1) ? argValue :
intermediate.addIndex(EOpIndexDirect, argValue, idxConst, loc);