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
Prior to the CL we cannot use the printer as that would trigger a recursion. So the only way out would be to create a new printer that has the same abilities as the current printer.
PiperOrigin-RevId: 489024852
Xcode 14 is warning:
```
warning: Run script build phase 'Script: Check Runtime Stamps' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking "Based on dependency analysis" in the script phase. (in target 'UnitTests' from project 'ProtocolBuffers_OSX')
```
This setting avoids that warning.
PiperOrigin-RevId: 488703116
- FieldDescriptor:
- Add a new flag to mark when the enum on the field is closed (vs open).
- Support computing the state for when generated sources predate the support.
- EnumDescriptor:
- Support passing flags to the descriptor creation, currently closed is the
only new flag.
- Add an isClosed property to expose the state of the enum.
This does NOT update generation yet, allows things to be tested before the
generation support is added.
PiperOrigin-RevId: 488671606
- Streamline the FieldDescriptor loop a little.
- Move some of the init methods from PackagePrivate into the impl file as
nothing outside calls them and it better encapsulates the signature.
PiperOrigin-RevId: 488671041
The static analyzer in some versions of Xcode now flag the enumDescriptor_ as
retained by the generated methods and not being release in dealloc. So avoid the
whole issue by just bringing back the explicit getter.
PiperOrigin-RevId: 488436139
Going back to the first ObjC support commit, there never really was support for
not have the EnumDescriptors, so start removing that partial support.
PiperOrigin-RevId: 488381501