diff options
author | Joshua Haberman <jhaberman@gmail.com> | 2016-09-09 14:59:47 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-09 14:59:47 -0700 |
commit | b176b976a5f941a73b2247b3ae8473bf1c0c0fa7 (patch) | |
tree | 48defe635c420f6056b66bb0b7294e1efdf7d610 /tests/test.proto | |
parent | 0787643281ff264b39bbede82af651770c08eab7 (diff) | |
parent | c387d372ee42d338ca03d91112370c532c6bc574 (diff) |
Merge pull request #69 from haberman/oneofdesc
Added support for loading oneofs from descriptors.
Diffstat (limited to 'tests/test.proto')
-rw-r--r-- | tests/test.proto | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/test.proto b/tests/test.proto index 40e185b..e790cbf 100644 --- a/tests/test.proto +++ b/tests/test.proto @@ -6,6 +6,8 @@ // ^ |`---|--------^ // +----------+----+ F +syntax = "proto2"; + message A { optional B b = 1; } @@ -46,4 +48,21 @@ message SimplePrimitives { optional sint32 i32 = 7; optional bool b = 8; optional string str = 9; + + oneof foo { + int32 oneof_int32 = 10; + string oneof_string = 11; + } + + oneof bar { + int64 oneof_int64 = 13; + bytes oneof_bytes = 14; + } + + message Nested { + oneof foo { + int32 oneof_int32 = 10; + string b = 11; + } + } } |