Support dynamic allocation for string, bytes and message fields.
This is turned on by passing -p to nanopb_generator.py or setting the (nanopb).pointer option for a .proto field. git-svn-id: https://svn.kapsi.fi/jpa/nanopb-dev@1081 e3a754e5-d11d-0410-8d38-ebb782a927b9
This commit is contained in:
committed by
Petteri Aimonen
parent
8e5337e9ef
commit
c66c6b43c4
@@ -1,6 +1,7 @@
|
||||
// Custom options for defining:
|
||||
// - Maximum size of string/bytes
|
||||
// - Maximum number of elements in array
|
||||
// - Pointer or in-line representation of non-scalar fields
|
||||
//
|
||||
// These are used by nanopb to generate statically allocable structures
|
||||
// for memory-limited environments.
|
||||
@@ -10,6 +11,7 @@ import "google/protobuf/descriptor.proto";
|
||||
message NanoPBOptions {
|
||||
optional int32 max_size = 1;
|
||||
optional int32 max_count = 2;
|
||||
optional bool pointer = 3;
|
||||
}
|
||||
|
||||
// Protocol Buffers extension number registry
|
||||
|
||||
Reference in New Issue
Block a user