Skip to content

Commit

Permalink
Automated rollback of commit 2a55706. (#14246)
Browse files Browse the repository at this point in the history
* Automated rollback of commit 2a55706.

PiperOrigin-RevId: 569253919

* Remove editions handling not relevant in 24.x
  • Loading branch information
zhangskz authored Sep 28, 2023
1 parent e4baf96 commit b9cf19b
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2461,7 +2461,10 @@ public void clear(final GeneratedMessageV3.Builder<?> builder) {
final String containingOneofCamelCaseName) {
isOneofField =
descriptor.getRealContainingOneof() != null;
hasHasMethod = descriptor.hasPresence();
hasHasMethod =
descriptor.getFile().getSyntax() == FileDescriptor.Syntax.PROTO2
|| descriptor.hasOptionalKeyword()
|| (!isOneofField && descriptor.getJavaType() == FieldDescriptor.JavaType.MESSAGE);
ReflectionInvoker reflectionInvoker =
new ReflectionInvoker(
descriptor,
Expand Down

0 comments on commit b9cf19b

Please sign in to comment.