Skip to content
This repository was archived by the owner on Jul 19, 2018. It is now read-only.

Commit 3b13ef6

Browse files
committed
layers:Update comments to avoid compiler warnings
The simple "// fall through" comment causes the compiler to omit a warning.
1 parent 3014506 commit 3b13ef6

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

layers/buffer_validation.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1175,10 +1175,10 @@ static bool RegionIntersects(const VkImageCopy *rgn0, const VkImageCopy *rgn1, V
11751175
switch (type) {
11761176
case VK_IMAGE_TYPE_3D:
11771177
result &= RangesIntersect(rgn0->srcOffset.z, rgn0->extent.depth, rgn1->dstOffset.z, rgn1->extent.depth);
1178-
// Intentionally fall through to 2D case
1178+
// fall through
11791179
case VK_IMAGE_TYPE_2D:
11801180
result &= RangesIntersect(rgn0->srcOffset.y, rgn0->extent.height, rgn1->dstOffset.y, rgn1->extent.height);
1181-
// Intentionally fall through to 1D case
1181+
// fall through
11821182
case VK_IMAGE_TYPE_1D:
11831183
result &= RangesIntersect(rgn0->srcOffset.x, rgn0->extent.width, rgn1->dstOffset.x, rgn1->extent.width);
11841184
break;
@@ -1365,11 +1365,11 @@ static inline bool CheckItgExtent(layer_data *device_data, const GLOBAL_CB_NODE
13651365
case VK_IMAGE_TYPE_3D:
13661366
z_ok = ((0 == SafeModulo(extent->depth, granularity->depth)) ||
13671367
(subresource_extent->depth == offset_extent_sum.depth));
1368-
// Intentionally fall through to 2D case
1368+
// fall through
13691369
case VK_IMAGE_TYPE_2D:
13701370
y_ok = ((0 == SafeModulo(extent->height, granularity->height)) ||
13711371
(subresource_extent->height == offset_extent_sum.height));
1372-
// Intentionally fall through to 1D case
1372+
// fall through
13731373
case VK_IMAGE_TYPE_1D:
13741374
x_ok = ((0 == SafeModulo(extent->width, granularity->width)) ||
13751375
(subresource_extent->width == offset_extent_sum.width));
@@ -2977,7 +2977,7 @@ bool ValidateLayouts(core_validation::layer_data *device_data, VkDevice device,
29772977
} else {
29782978
// Intentionally fall through to generic error message
29792979
}
2980-
2980+
// fall through
29812981
default:
29822982
// No other layouts are acceptable
29832983
skip |= log_msg(report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_UNKNOWN_EXT, 0,

layers/descriptor_sets.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1884,8 +1884,8 @@ bool cvdescriptorset::DescriptorSet::VerifyWriteUpdateContents(const VkWriteDesc
18841884
return false;
18851885
}
18861886
}
1887-
// Intentional fall-through to validate sampler
18881887
}
1888+
// fall through
18891889
case VK_DESCRIPTOR_TYPE_SAMPLER: {
18901890
for (uint32_t di = 0; di < update->descriptorCount; ++di) {
18911891
if (!descriptors_[index + di].get()->IsImmutableSampler()) {

0 commit comments

Comments
 (0)