Commit Graph

8 Commits (main)

Author SHA1 Message Date
Sandy Zhang c99cf4bbfa Add `java` to reserved names to escape extensions to `java_`. This may break existing references to gencode for extensions named `java`.
This prevents shadowing of `java.lang` package commonly used in protobuf gencode. Existing extensions named `java` may or may not previously fail to compile depending on if the contents of their .proto result in gencode using `java.lang`. This is needed to fix `java_features.proto` lite gencode since enum gencode uses `java.lang`. Fields named `java` should already be escaped.

*Warning: This may break user code for existing protos with extensions named `java`. References to the extension should be renamed to use `java_` e.g. registry.add(GeneratedClassName.java_)*

PiperOrigin-RevId: 632508249
2024-05-10 08:49:22 -07:00
Brent Shaffer 01744cccae chore(php): conformance testing for edition (#16712)
COPYBARA_INTEGRATE_REVIEW=https://github.com/protocolbuffers/protobuf/pull/16712 from bshaffer:php-editions a1c41add7d
PiperOrigin-RevId: 631824623
2024-05-08 09:23:08 -07:00
Protobuf Team Bot d45016a93f Internal changes to versions
PiperOrigin-RevId: 631435235
2024-05-07 08:44:48 -07:00
Protobuf Team Bot 2c246484d3 Add editions-specific required fields to the required fields allow-list.
PiperOrigin-RevId: 629433997
2024-04-30 09:16:29 -07:00
Protobuf Team Bot a9e0480768 Use Emit for ByteSizeLong
PiperOrigin-RevId: 627204923
2024-04-22 17:32:05 -07:00
Mike Kruskal 57a6e8df1c Add dedicated tests to lock down that overridable defaults never change.
Once an edition is released these should be fixed forever.  On the other hand, the fixed defaults may see new features included as we change legacy behaviors in future editions.

PiperOrigin-RevId: 625842071
2024-04-17 16:36:06 -07:00
Mike Kruskal db5814e4ff Use newly split feature defaults in plugins and runtimes.
The new fields fixed_features and overridable_features can be simply merged to recover the old aggregate defaults.  By splitting them though, plugins and runtimes get some extra information about lifetimes for enforcement.

PiperOrigin-RevId: 625527117
2024-04-16 19:18:40 -07:00
Mike Kruskal ea81024ddf Refactor editions infrastructure to a top-level directory.
The only public target here is the edition defaults helper macro, which can be used by external runtimes and plugins.  None of this code is C++-specific though, and should be organized higher up.  Appropriate aliases are also placed at the top level for public targets

PiperOrigin-RevId: 625392504
2024-04-16 11:13:19 -07:00