From b9bde6a87c5da399431938f7c9280d87274f9cee Mon Sep 17 00:00:00 2001 From: Protobuf Team Bot Date: Wed, 3 Apr 2024 19:25:27 +0000 Subject: [PATCH] Auto-generate files after cl/621597812 --- php/ext/google/protobuf/php-upb.c | 20 ++++++++++---------- php/ext/google/protobuf/php-upb.h | 11 +++++------ ruby/ext/google/protobuf_c/ruby-upb.c | 20 ++++++++++---------- ruby/ext/google/protobuf_c/ruby-upb.h | 11 +++++------ src/file_lists.cmake | 2 +- 5 files changed, 31 insertions(+), 33 deletions(-) diff --git a/php/ext/google/protobuf/php-upb.c b/php/ext/google/protobuf/php-upb.c index 4c4ef5cbf1..53a5885c3b 100644 --- a/php/ext/google/protobuf/php-upb.c +++ b/php/ext/google/protobuf/php-upb.c @@ -8958,12 +8958,12 @@ upb_DecodeStatus upb_Decode(const char* buf, size_t size, upb_Message* msg, return upb_Decoder_Decode(&decoder, buf, msg, mt, arena); } -upb_DecodeStatus upb_DecodeLengthDelimited(const char* buf, size_t size, - upb_Message* msg, - size_t* num_bytes_read, - const upb_MiniTable* mt, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +upb_DecodeStatus upb_DecodeLengthPrefixed(const char* buf, size_t size, + upb_Message* msg, + size_t* num_bytes_read, + const upb_MiniTable* mt, + const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { // To avoid needing to make a Decoder just to decode the initial length, // hand-decode the leading varint for the message length here. uint64_t msg_len = 0; @@ -9626,10 +9626,10 @@ upb_EncodeStatus upb_Encode(const upb_Message* msg, const upb_MiniTable* l, return _upb_Encode(msg, l, options, arena, buf, size, false); } -upb_EncodeStatus upb_EncodeLengthDelimited(const upb_Message* msg, - const upb_MiniTable* l, int options, - upb_Arena* arena, char** buf, - size_t* size) { +upb_EncodeStatus upb_EncodeLengthPrefixed(const upb_Message* msg, + const upb_MiniTable* l, int options, + upb_Arena* arena, char** buf, + size_t* size) { return _upb_Encode(msg, l, options, arena, buf, size, true); } diff --git a/php/ext/google/protobuf/php-upb.h b/php/ext/google/protobuf/php-upb.h index 5ebb708a67..16e3493544 100644 --- a/php/ext/google/protobuf/php-upb.h +++ b/php/ext/google/protobuf/php-upb.h @@ -4148,7 +4148,7 @@ UPB_API upb_DecodeStatus upb_Decode(const char* buf, size_t size, // Same as upb_Decode but with a varint-encoded length prepended. // On success 'num_bytes_read' will be set to the how many bytes were read, // on failure the contents of num_bytes_read is undefined. -UPB_API upb_DecodeStatus upb_DecodeLengthDelimited( +UPB_API upb_DecodeStatus upb_DecodeLengthPrefixed( const char* buf, size_t size, upb_Message* msg, size_t* num_bytes_read, const upb_MiniTable* mt, const upb_ExtensionRegistry* extreg, int options, upb_Arena* arena); @@ -4220,11 +4220,10 @@ UPB_API upb_EncodeStatus upb_Encode(const upb_Message* msg, upb_Arena* arena, char** buf, size_t* size); // Encodes the message prepended by a varint of the serialized length. -UPB_API upb_EncodeStatus upb_EncodeLengthDelimited(const upb_Message* msg, - const upb_MiniTable* l, - int options, - upb_Arena* arena, char** buf, - size_t* size); +UPB_API upb_EncodeStatus upb_EncodeLengthPrefixed(const upb_Message* msg, + const upb_MiniTable* l, + int options, upb_Arena* arena, + char** buf, size_t* size); #ifdef __cplusplus } /* extern "C" */ diff --git a/ruby/ext/google/protobuf_c/ruby-upb.c b/ruby/ext/google/protobuf_c/ruby-upb.c index feda81448b..626078c84d 100644 --- a/ruby/ext/google/protobuf_c/ruby-upb.c +++ b/ruby/ext/google/protobuf_c/ruby-upb.c @@ -8451,12 +8451,12 @@ upb_DecodeStatus upb_Decode(const char* buf, size_t size, upb_Message* msg, return upb_Decoder_Decode(&decoder, buf, msg, mt, arena); } -upb_DecodeStatus upb_DecodeLengthDelimited(const char* buf, size_t size, - upb_Message* msg, - size_t* num_bytes_read, - const upb_MiniTable* mt, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +upb_DecodeStatus upb_DecodeLengthPrefixed(const char* buf, size_t size, + upb_Message* msg, + size_t* num_bytes_read, + const upb_MiniTable* mt, + const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { // To avoid needing to make a Decoder just to decode the initial length, // hand-decode the leading varint for the message length here. uint64_t msg_len = 0; @@ -9119,10 +9119,10 @@ upb_EncodeStatus upb_Encode(const upb_Message* msg, const upb_MiniTable* l, return _upb_Encode(msg, l, options, arena, buf, size, false); } -upb_EncodeStatus upb_EncodeLengthDelimited(const upb_Message* msg, - const upb_MiniTable* l, int options, - upb_Arena* arena, char** buf, - size_t* size) { +upb_EncodeStatus upb_EncodeLengthPrefixed(const upb_Message* msg, + const upb_MiniTable* l, int options, + upb_Arena* arena, char** buf, + size_t* size) { return _upb_Encode(msg, l, options, arena, buf, size, true); } diff --git a/ruby/ext/google/protobuf_c/ruby-upb.h b/ruby/ext/google/protobuf_c/ruby-upb.h index f19d6db510..7a84ef1ba6 100755 --- a/ruby/ext/google/protobuf_c/ruby-upb.h +++ b/ruby/ext/google/protobuf_c/ruby-upb.h @@ -4150,7 +4150,7 @@ UPB_API upb_DecodeStatus upb_Decode(const char* buf, size_t size, // Same as upb_Decode but with a varint-encoded length prepended. // On success 'num_bytes_read' will be set to the how many bytes were read, // on failure the contents of num_bytes_read is undefined. -UPB_API upb_DecodeStatus upb_DecodeLengthDelimited( +UPB_API upb_DecodeStatus upb_DecodeLengthPrefixed( const char* buf, size_t size, upb_Message* msg, size_t* num_bytes_read, const upb_MiniTable* mt, const upb_ExtensionRegistry* extreg, int options, upb_Arena* arena); @@ -4222,11 +4222,10 @@ UPB_API upb_EncodeStatus upb_Encode(const upb_Message* msg, upb_Arena* arena, char** buf, size_t* size); // Encodes the message prepended by a varint of the serialized length. -UPB_API upb_EncodeStatus upb_EncodeLengthDelimited(const upb_Message* msg, - const upb_MiniTable* l, - int options, - upb_Arena* arena, char** buf, - size_t* size); +UPB_API upb_EncodeStatus upb_EncodeLengthPrefixed(const upb_Message* msg, + const upb_MiniTable* l, + int options, upb_Arena* arena, + char** buf, size_t* size); #ifdef __cplusplus } /* extern "C" */ diff --git a/src/file_lists.cmake b/src/file_lists.cmake index 2642243b15..554ae81221 100644 --- a/src/file_lists.cmake +++ b/src/file_lists.cmake @@ -969,7 +969,7 @@ set(upb_test_files ${protobuf_SOURCE_DIR}/upb/message/test.cc ${protobuf_SOURCE_DIR}/upb/message/utf8_test.cc ${protobuf_SOURCE_DIR}/upb/test/editions_test.cc - ${protobuf_SOURCE_DIR}/upb/test/length_delimited_test.cc + ${protobuf_SOURCE_DIR}/upb/test/length_prefixed_test.cc ${protobuf_SOURCE_DIR}/upb/test/proto3_test.cc ${protobuf_SOURCE_DIR}/upb/test/test_cpp.cc ${protobuf_SOURCE_DIR}/upb/test/test_generated_code.cc