LazyField explicitly registers `ArenaDtor` for destructing the lazy Cord contents which is particularly heavily used in extension sets. This is inefficient as it requires an indirect thunk call into the lazy field instance which then itself calls the Cord destructor. We can directly register the Cord for destruction which results in half the cleanup space (Tagged cleanup), and a direct call into the Cord destructor.
PiperOrigin-RevId: 491379222
For normal fields, closed enums get their out of range values put into unknown
fields, but that wasn't happening for extension fields, this fixes that by
adding the validation during parsing.
Also document on the getExtension API what happens with enums.
Add tests to confirm expected behaviors.
PiperOrigin-RevId: 491356730
Create/Collect all the MessageGenerators/EnumGenerators/ExtensionGeneators up at
the FileGenerator level and remove the need for some helpers and need for
generation apis to recurse through the generators.
The only change to the .pbobjc.m files is positionally where the enum support
for nested enums appears, it now is the same order as it was in the .pbobjc.h
files instead of being closer the the type it was nested in.
PiperOrigin-RevId: 491343515
The avoids passing four arguments and instead just passes one, so there tradeoff
in code is likely slightly better and from a perf pov, likely a wash.
PiperOrigin-RevId: 490540510
They probably should be hidden on every ELF platform, but for now only do it on Darwin, Linux, and FreeBSD.
This prevents some load-time errors that have been seen in GitLab's gitaly server, and in a few other places.
Closes#10832
COPYBARA_INTEGRATE_REVIEW=https://github.com/protocolbuffers/protobuf/pull/10832 from dankm:hide-symbols 4cb59f2691
PiperOrigin-RevId: 490522474
The README file had not a consistent handling of links. Sometimes there was a Link with Text sometimes there was a Linked URL. Sometimes there was «here» mentioned in the text.
The changes were made under the following rules:
* Links have a URL and a text
* Link-Text is a (human) meaningful description of the target (machine) URL
What was not touched/fixed:
* Line-breaks at different width
reassign sys.stdin and sys.stdout with files that do not match the text API
contract of those. This fixes a stdin pipe IO race condition on input that was
leading to flakiness depending on the test system load.
PiperOrigin-RevId: 489320918