Web: Remove/rationalize a set of *_EXTENSIONS, using GLSLANG_WEB.
Focus was on the front end (not SPIR-V), minus the grammar. Reduces #ifdef count by around 320 and makes the web build 270K smaller, which is about 90% the target size. The grammar and scanner will be another step, as will the SPIR-V backend. This makes heavy use of methods #ifdef'd to return false as a global way of turning off code, relying on C++ DCE to do the rest.
This commit is contained in:
parent
e66dace97e
commit
7015bd658e
32 changed files with 2661 additions and 2712 deletions
|
|
@ -152,12 +152,10 @@ bool TParseContextBase::lValueErrorCheck(const TSourceLoc& loc, const char* op,
|
|||
case EvqBuffer:
|
||||
if (node->getQualifier().readonly)
|
||||
message = "can't modify a readonly buffer";
|
||||
#ifdef NV_EXTENSIONS
|
||||
if (node->getQualifier().layoutShaderRecordNV)
|
||||
if (node->getQualifier().isShaderRecordNV())
|
||||
message = "can't modify a shaderrecordnv qualified buffer";
|
||||
#endif
|
||||
break;
|
||||
#ifdef NV_EXTENSIONS
|
||||
#ifndef GLSLANG_WEB
|
||||
case EvqHitAttrNV:
|
||||
if (language != EShLangIntersectNV)
|
||||
message = "cannot modify hitAttributeNV in this stage";
|
||||
|
|
@ -178,7 +176,7 @@ bool TParseContextBase::lValueErrorCheck(const TSourceLoc& loc, const char* op,
|
|||
case EbtVoid:
|
||||
message = "can't modify void";
|
||||
break;
|
||||
#ifdef NV_EXTENSIONS
|
||||
#ifndef GLSLANG_WEB
|
||||
case EbtAccStructNV:
|
||||
message = "can't modify accelerationStructureNV";
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue