The Nanopb implementation (plain C, not C++) has a max_size option:

string name = 1 [(nanopb).max_size = 40];

will generate the following C declaration:

char name[40];

See http://koti.kapsi.fi/~jpa/nanopb/docs/concepts.html

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/protobuf/-/grdbiljsrXUJ.
To post to this group, send email to protobuf@googlegroups.com.
To unsubscribe from this group, send email to 
protobuf+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en.

Reply via email to