Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a oneof with several message fields to inspect the codegen for a future #20031

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions editions/golden/test_messages_proto2_editions.proto
Original file line number Diff line number Diff line change
Expand Up @@ -640,3 +640,28 @@ message TestAllRequiredTypesProto2 {
];
}
}

message TestLargeOneof {
message A1 {
}

message A2 {
}

message A3 {
}

message A4 {
}

message A5 {
}

oneof large_oneof {
A1 a1 = 1;
A2 a2 = 2;
A3 a3 = 3;
A4 a4 = 4;
A5 a5 = 5;
}
}
15 changes: 15 additions & 0 deletions src/google/protobuf/test_messages_proto2.proto
Original file line number Diff line number Diff line change
Expand Up @@ -385,3 +385,18 @@ message TestAllRequiredTypesProto2 {
required int32 i = 9;
}
}

message TestLargeOneof {
message A1 {}
message A2 {}
message A3 {}
message A4 {}
message A5 {}
oneof large_oneof {
A1 a1 = 1;
A2 a2 = 2;
A3 a3 = 3;
A4 a4 = 4;
A5 a5 = 5;
}
}
Loading