Don't miss end_group_tag when counting try_num_fast_fields.

PiperOrigin-RevId: 547705006
pull/13285/head
Protobuf Team Bot 2 years ago committed by Copybara-Service
parent 8b1c305137
commit 5227e65bc1
  1. 2
      src/google/protobuf/generated_message_tctable_gen.cc

@ -855,7 +855,7 @@ TailCallTableInfo::TailCallTableInfo(
ABSL_CHECK_EQ(split_fields.size(), try_size); ABSL_CHECK_EQ(split_fields.size(), try_size);
int try_num_fast_fields = 0; int try_num_fast_fields = 0;
for (const auto& info : split_fields) { for (const auto& info : split_fields) {
if (info.field != nullptr) ++try_num_fast_fields; if (!info.func_name.empty()) ++try_num_fast_fields;
} }
// Use this size if (and only if) it covers more fields. // Use this size if (and only if) it covers more fields.
if (try_num_fast_fields > num_fast_fields) { if (try_num_fast_fields > num_fast_fields) {

Loading…
Cancel
Save