|
|
|
@ -6287,7 +6287,7 @@ typedef enum { |
|
|
|
|
kUpb_LayoutItemType_Max = kUpb_LayoutItemType_Field, |
|
|
|
|
} upb_LayoutItemType; |
|
|
|
|
|
|
|
|
|
#define kUpb_LayoutItem_IndexSentinel ((uint16_t)-1) |
|
|
|
|
#define kUpb_LayoutItem_IndexSentinel ((uint16_t) - 1) |
|
|
|
|
|
|
|
|
|
typedef struct { |
|
|
|
|
// Index of the corresponding field. When this is a oneof field, the field's
|
|
|
|
@ -6976,6 +6976,11 @@ static upb_MiniTable* upb_MtDecoder_DoBuildMiniTableWithBuf( |
|
|
|
|
decoder->table->UPB_PRIVATE(dense_below) = 0; |
|
|
|
|
decoder->table->UPB_PRIVATE(table_mask) = -1; |
|
|
|
|
decoder->table->UPB_PRIVATE(required_count) = 0; |
|
|
|
|
#if UPB_TRACING_ENABLED |
|
|
|
|
// MiniTables built from MiniDescriptors will not be able to vend the message
|
|
|
|
|
// name unless it is explicitly set with upb_MiniTable_SetFullName().
|
|
|
|
|
decoder->table->UPB_PRIVATE(full_name) = 0; |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
// Strip off and verify the version tag.
|
|
|
|
|
if (!len--) goto done; |
|
|
|
@ -11875,6 +11880,23 @@ bool UPB_PRIVATE(_upb_Message_Realloc)(struct upb_Message* msg, size_t need, |
|
|
|
|
return true; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
#if UPB_TRACING_ENABLED |
|
|
|
|
static void (*_new_message_trace_handler)(const upb_MiniTable*, |
|
|
|
|
const upb_Arena*); |
|
|
|
|
|
|
|
|
|
void upb_Message_SetNewMessageTraceHandler( |
|
|
|
|
void (*new_message_trace_handler)(const upb_MiniTable*, const upb_Arena*)) { |
|
|
|
|
_new_message_trace_handler = new_message_trace_handler; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void upb_Message_LogNewMessage(const upb_MiniTable* mini_table, |
|
|
|
|
const upb_Arena* arena) { |
|
|
|
|
if (_new_message_trace_handler) { |
|
|
|
|
_new_message_trace_handler(mini_table, arena); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const char _kUpb_ToBase92[] = { |
|
|
|
|
' ', '!', '#', '$', '%', '&', '(', ')', '*', '+', ',', '-', '.', '/', |
|
|
|
|