Separation Generator to a dedicated repo
[apps/low-level-can-service.git] / libs / nanopb / tests / anonymous_oneof / oneof.proto
1 syntax = "proto2";
2
3 import 'nanopb.proto';
4
5 message SubMessage
6 {
7     repeated int32 array = 1 [(nanopb).max_count = 8];
8 }
9
10 /* Oneof in a message with other fields */
11 message AnonymousOneOfMessage
12 {
13     option (nanopb_msgopt).anonymous_oneof = true;
14     required int32 prefix = 1;
15     oneof values
16     {
17         int32 first = 5;
18         string second = 6 [(nanopb).max_size = 8];
19         SubMessage third = 7;
20     }
21     required int32 suffix = 99;
22 }
23