Skip to content

Commit 1190d8f

Browse files
committed
style: fix clang-format issues
1 parent 10f5819 commit 1190d8f

1 file changed

Lines changed: 6 additions & 8 deletions

File tree

mooncake-store/src/master_service.cpp

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4444,10 +4444,10 @@ MasterService::MetadataSerializer::DeserializeMetadata(
44444444
// Deserialize replicas count
44454445
uint32_t replicas_count = array[index++].as<uint32_t>();
44464446

4447-
// Snapshot compatibility:
4448-
// 7 + replicas: legacy format
4449-
// 8 + replicas: either data_type or trailing hard_pinned
4450-
// 9 + replicas: data_type plus trailing hard_pinned
4447+
// Format detection:
4448+
// v1: 7 + replicas_count, no data_type or hard_pinned
4449+
// v2: 8 + replicas_count, either data_type or trailing hard_pinned
4450+
// v3: 9 + replicas_count, data_type plus trailing hard_pinned
44514451
constexpr uint32_t kOldFieldCount = 7;
44524452
constexpr uint32_t kOneExtraFieldCount = 8;
44534453
constexpr uint32_t kCurrentFieldCount = 9;
@@ -4467,12 +4467,10 @@ MasterService::MetadataSerializer::DeserializeMetadata(
44674467

44684468
ObjectDataType data_type = ObjectDataType::UNKNOWN;
44694469
if (is_current_format) {
4470-
data_type =
4471-
static_cast<ObjectDataType>(array[index++].as<uint8_t>());
4470+
data_type = static_cast<ObjectDataType>(array[index++].as<uint8_t>());
44724471
} else if (is_one_extra_format &&
44734472
array[index].type == msgpack::type::POSITIVE_INTEGER) {
4474-
data_type =
4475-
static_cast<ObjectDataType>(array[index++].as<uint8_t>());
4473+
data_type = static_cast<ObjectDataType>(array[index++].as<uint8_t>());
44764474
}
44774475

44784476
// Deserialize replicas

0 commit comments

Comments
 (0)