-
Notifications
You must be signed in to change notification settings - Fork 750
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix a typo in MixedDescriptors (getDescriptors -> getDescriptor)
PiperOrigin-RevId: 727839435
- Loading branch information
1 parent
711d705
commit faec219
Showing
1 changed file
with
5 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
A proto's `Descriptor` was created by mixing the `Descriptors` class from one | ||
proto with the field number from another. E.g.: | ||
A field `Descriptor` was created by mixing the message `Descriptor` from one | ||
proto message with the field number from another. For example: | ||
|
||
```java | ||
Foo.getDescriptors().findFieldByNumber(Bar.ID_FIELD_NUMBER) | ||
Foo.getDescriptor().findFieldByNumber(Bar.ID_FIELD_NUMBER) | ||
``` | ||
|
||
This accesses the `Descriptor` of a field in `Foo` with a field number from | ||
`Bar`. One of these was probably intended: | ||
|
||
```java | ||
Foo.getDescriptors().findFieldByNumber(Foo.ID_FIELD_NUMBER) | ||
Bar.getDescriptors().findFieldByNumber(Bar.ID_FIELD_NUMBER) | ||
Foo.getDescriptor().findFieldByNumber(Foo.ID_FIELD_NUMBER) | ||
Bar.getDescriptor().findFieldByNumber(Bar.ID_FIELD_NUMBER) | ||
``` |