Use [[fallthrough]] attribute instead of comments.

Now that we require C++17, the [[fallthrough]] attribute is available as
an alternative to load-bearing comments.
This commit is contained in:
Arcady Goldmints-Orlov 2024-02-19 18:42:55 -05:00 committed by arcady-lunarg
parent 8ca24e7cf1
commit 606209e07d
9 changed files with 22 additions and 21 deletions

View file

@ -8126,7 +8126,7 @@ void TBuiltIns::identifyBuiltIns(int version, EProfile profile, const SpvVersion
symbolTable.setFunctionExtensions("texture2DArrayLod", 1, &E_GL_EXT_texture_array);
symbolTable.setFunctionExtensions("shadow1DArrayLod", 1, &E_GL_EXT_texture_array);
}
// Fall through
[[fallthrough]];
case EShLangTessControl:
if (profile == EEsProfile && version >= 310) {
@ -8141,7 +8141,7 @@ void TBuiltIns::identifyBuiltIns(int version, EProfile profile, const SpvVersion
BuiltInVariable("gl_BoundingBox", EbvBoundingBox, symbolTable);
}
}
// Fall through
[[fallthrough]];
case EShLangTessEvaluation:
case EShLangGeometry:
@ -10231,7 +10231,8 @@ void TBuiltIns::identifyBuiltIns(int version, EProfile profile, const SpvVersion
if (profile != EEsProfile && version >= 460) {
symbolTable.relateToOperator("fetchMicroTriangleVertexPositionNV", EOpFetchMicroTriangleVertexPositionNV);
symbolTable.relateToOperator("fetchMicroTriangleVertexBarycentricNV", EOpFetchMicroTriangleVertexBarycentricNV);
} // fallthrough
}
[[fallthrough]];
case EShLangClosestHit:
case EShLangMiss:
if (profile != EEsProfile && version >= 460) {