summaryrefslogtreecommitdiff
path: root/src/upb.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/upb.h')
-rw-r--r--src/upb.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/upb.h b/src/upb.h
index ff7c86e..0ee40fb 100644
--- a/src/upb.h
+++ b/src/upb.h
@@ -29,8 +29,11 @@ extern "C" {
// The maximum that any submessages can be nested. Matches proto2's limit.
#define UPB_MAX_NESTING 64
-// The maximum number of fields that any one .proto type can have.
-#define UPB_MAX_FIELDS (1<<16)
+// The maximum number of fields that any one .proto type can have. Note that
+// this is very different than the max field number. It is hard to imagine a
+// scenario where more than 32k fields makes sense.
+#define UPB_MAX_FIELDS (1<<15)
+typedef int16_t upb_field_count_t;
// Nested type names are separated by periods.
#define UPB_SYMBOL_SEPARATOR '.'
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback