diff options
author | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2015-01-11 19:38:05 +0200 |
---|---|---|
committer | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2015-01-11 19:45:16 +0200 |
commit | 8d12fecc7e4fb6899eb0d013abe0d6a5e03447ce (patch) | |
tree | cdb069ee1435a8a00d790fef027d7865ee6e0199 /generator/proto/nanopb.proto | |
parent | 8ef0392231c071a92ae78113763c0b1d61eafb1f (diff) |
New generator options for oneofs: allow skipping or generating as normal 'optional' fields.
The behaviour with no_unions:true is the same as of nanopb 0.3.1 and earlier.
Diffstat (limited to 'generator/proto/nanopb.proto')
-rw-r--r-- | generator/proto/nanopb.proto | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/generator/proto/nanopb.proto b/generator/proto/nanopb.proto index e830ec2c..a1b24936 100644 --- a/generator/proto/nanopb.proto +++ b/generator/proto/nanopb.proto @@ -53,6 +53,9 @@ message NanoPBOptions { // Skip this message optional bool skip_message = 6 [default = false]; + + // Generate oneof fields as normal optional fields instead of union. + optional bool no_unions = 8 [default = false]; } // Extensions to protoc 'Descriptor' type in order to define options |