summaryrefslogtreecommitdiffstats
path: root/tests/inputs/oneof/oneof.proto
blob: 41f93b0e0bc487f24bdf7fff28d130f43c5c36cb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
syntax = "proto3";

package oneof;

message MixedDrink {
  int32 shots = 1;
}

message Test {
  oneof foo {
    int32 pitied = 1;
    string pitier = 2;
  }

  int32 just_a_regular_field = 3;

  oneof bar {
    int32 drinks = 11;
    string bar_name = 12;
    MixedDrink mixed_drink = 13;
  }
}