~thopiekar/protobuf/+git/protobuf:main

Last commit made on 2024-05-03
Get this branch:
git clone -b main https://git.launchpad.net/~thopiekar/protobuf/+git/protobuf

Branch merges

Branch information

Name:
main
Repository:
lp:~thopiekar/protobuf/+git/protobuf

Recent commits

733b9c5... by =?utf-8?q?Adrian_Sad=C5=82ocha?= <email address hidden>

Implement `is_known` method on the `Enum` trait

This is equivalent to C++'s `_IsValid` functions. Since proto3 enums are open,
`is_known` seems to be a better name than the misleading `is_valid`.

C++-specific Protocol Buffers documentation already uses "known fields" and
"unknown enum values" expressions.

PiperOrigin-RevId: 630344180

d9ff109... by Protobuf Team Bot <email address hidden>

internal change

PiperOrigin-RevId: 630273635

4f12891... by Mark Hansen <email address hidden>

Java full runtime: Avoid allocating iterator if UnknownFieldSet's TreeMap is empty

I also considered using Collections.emptyNavigableMap(), which I thought might
use a specialized allocation free empty iterator, but it allocates, and its
clone() method isn't nicely exposed.

PiperOrigin-RevId: 630234849

cc79f77... by Mark Hansen <email address hidden>

Proto java full runtime: avoid allocating Integers accessing enum lists

Previously, we would allocate a boxed Integer when accessing repeated enums, because we used ArrayList<Integer>, which must box the int.

Use IntArrayList and the primitive "int getInt()" method instead.

PiperOrigin-RevId: 630229119

d6c2833... by Mike Kruskal <email address hidden>

Fix validation checks of implicit presence.

Instead of checking the resolved features, we should really be checking the has_presence helper. Repeated fields, oneofs, and extensions can trigger these conditions when they inherit IMPLICIT, even though it's ignored.

Closes #16664

PiperOrigin-RevId: 630206208

0dbd99a... by Mike Kruskal <email address hidden>

Clarify map behaviors in editions.

Map fields should remain length-prefixed for now, even if DELIMITED is inherited. Field presence will remain unchanged, but unit-tests are added to make sure proto2/proto3 behaviors stay consistent.

Closes #16549

PiperOrigin-RevId: 630191163

9340eec... by Protobuf Team Bot <email address hidden>

Auto-generate files after cl/630099889

2257232... by Mike Kruskal <email address hidden>

Split bootstrapped java_features.proto to keep it from leaking out.

This can cause ODR violations in downstream users who link against both the bootstrapped proto and transitive C++ gencode of java_features.proto. Once protoc is split up, we can turn the bootstrapped proto into a real cc_proto_library target and avoid this problem altogether.

PiperOrigin-RevId: 630099889

d3b2fc5... by Protobuf Team Bot <email address hidden>

Auto-generate files after cl/630090538

c9eeb1c... by Protobuf Team Bot <email address hidden>

Internal changes.

PiperOrigin-RevId: 630090538