Parser: Redeclare gl_ClipDistance/gl_CullDistance should update their array sizes.

This commit is contained in:
Rex Xu 2016-05-11 15:50:41 +08:00
parent 3357d870e4
commit 827b23b8a1
8 changed files with 34 additions and 31 deletions

View file

@ -3465,6 +3465,9 @@ void TParseContext::redeclareBuiltinBlock(const TSourceLoc& loc, TTypeList& newT
oldType.getQualifier().flat = newType.getQualifier().flat;
oldType.getQualifier().nopersp = newType.getQualifier().nopersp;
if (oldType.isImplicitlySizedArray() && newType.isExplicitlySizedArray())
oldType.changeOuterArraySize(newType.getOuterArraySize());
// go to next member
++member;
} else {