diff --git a/src/google/protobuf/editions/codegen_tests/proto3_packed.proto b/src/google/protobuf/editions/codegen_tests/proto3_packed.proto index ed7e38f404..3f511b540f 100644 --- a/src/google/protobuf/editions/codegen_tests/proto3_packed.proto +++ b/src/google/protobuf/editions/codegen_tests/proto3_packed.proto @@ -16,4 +16,5 @@ message Proto3Packed { int32 int32_field = 1; } repeated SubMessage sub_message_field = 3; + repeated int32 explicitly_packed = 4 [packed = true]; } diff --git a/src/google/protobuf/editions/golden/editions_transform_proto2.proto b/src/google/protobuf/editions/golden/editions_transform_proto2.proto index 37ceb7bfdd..0e538701b0 100644 --- a/src/google/protobuf/editions/golden/editions_transform_proto2.proto +++ b/src/google/protobuf/editions/golden/editions_transform_proto2.proto @@ -14,6 +14,7 @@ edition = "2023"; package protobuf_editions_test; +import "net/proto/proto1_features.proto"; import "third_party/java_src/protobuf/current/java/com/google/protobuf/java_features.proto"; import "google/protobuf/cpp_features.proto"; import "google/protobuf/editions/proto/editions_transform_proto3.proto"; @@ -78,7 +79,8 @@ message TestMessage { map string_map_field = 7; repeated int32 int_field = 8; repeated int32 int_field_packed = 9 [ - features.repeated_field_encoding = PACKED + features.repeated_field_encoding = PACKED, + features.(pb.proto1).legacy_packed = true ]; repeated int32 int_field_unpacked = 10; diff --git a/src/google/protobuf/editions/golden/editions_transform_proto3.proto b/src/google/protobuf/editions/golden/editions_transform_proto3.proto index 80123f4e50..cbb91d0fc0 100644 --- a/src/google/protobuf/editions/golden/editions_transform_proto3.proto +++ b/src/google/protobuf/editions/golden/editions_transform_proto3.proto @@ -9,6 +9,8 @@ edition = "2023"; package protobuf_editions_test; +import "net/proto/proto1_features.proto"; + option features.field_presence = IMPLICIT; enum TestEnumProto3 { @@ -20,7 +22,10 @@ message TestMessageProto3 { string string_field = 1; map string_map_field = 4; repeated int32 int_field = 7; - repeated int32 int_field_packed = 8; + repeated int32 int_field_packed = 8 [ + features.(pb.proto1).legacy_packed = true + ]; + repeated int32 int_field_unpacked = 9 [ features.repeated_field_encoding = EXPANDED ];