From 9c818fa15aa77290a81ccd7ed549ca89dd478a7c Mon Sep 17 00:00:00 2001 From: Protobuf Team Bot Date: Thu, 20 Nov 2025 16:36:45 -0800 Subject: [PATCH] Internal change PiperOrigin-RevId: 834959550 --- src/google/protobuf/port.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/google/protobuf/port.h b/src/google/protobuf/port.h index 583a70553c840..2b7fcb9b50078 100644 --- a/src/google/protobuf/port.h +++ b/src/google/protobuf/port.h @@ -665,6 +665,14 @@ inline bool IsMemoryPoisoned([[maybe_unused]] const void* p) { #endif } +inline constexpr bool ShouldBatchRepeatedNumeric() { +#ifdef PROTOBUF_INTERNAL_BATCH_REPEATED_NUMERIC + return true; +#else + return false; +#endif +} + #if defined(ABSL_HAVE_THREAD_SANITIZER) // TODO: it would be preferable to use __tsan_external_read/ // __tsan_external_write, but they can cause dlopen issues.