Skip to content

Commit 798fa3f

Browse files
Protocol Buffer TeamLogofile
authored andcommitted
This change includes the following:
* Reordering the table of contents by updating the weight metadata in the `features.md` topic * Adding a link to the Proto best practices topic from within `style.md` * Updating the `version-support.md` topic with information about the 25.x release PiperOrigin-RevId: 579176393 Change-Id: Ie5b115b7d2405e2bbf04a668168f37a99f387d47
1 parent 43fd4fb commit 798fa3f

File tree

3 files changed

+178
-158
lines changed

3 files changed

+178
-158
lines changed

content/editions/features.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
+++
22
title = "Feature Settings for Editions"
3-
weight = 42
3+
weight = 43
44
description = "Protobuf Editions features and how they affect protobuf behavior."
55
type = "docs"
66
+++

content/programming-guides/style.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,14 @@ enum FooBar {
9898
```
9999

100100
Each enum value should end with a semicolon, not a comma. Prefer prefixing enum
101-
values instead of surrounding them in an enclosing message. The zero value enum
102-
should have the suffix `UNSPECIFIED`, because a server or application that gets
103-
an unexpected enum value will mark the field as unset in the proto instance. The
104-
field accessor will then return the default value, which for enum fields is the
105-
first enum value.
101+
values instead of surrounding them in an enclosing message.
102+
103+
The zero value enum should have the suffix `UNSPECIFIED`, because a server or
104+
application that gets an unexpected enum value will mark the field as unset in
105+
the proto instance. The field accessor will then return the default value, which
106+
for enum fields is the first enum value. For more information on the unspecified
107+
enum value, see
108+
[the Proto Best Practices page](/programming-guides/dos-donts#unspecified-enum).
106109

107110
## Services {#services}
108111

0 commit comments

Comments
 (0)