-
Notifications
You must be signed in to change notification settings - Fork 15.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use
toUnsignedString()
to convert uint32
and uint64
to strings.
This method has existed since Java 8, released in 2014. Also adjust the tests so that they verify unsigned integer values that are too big for the signed counterpart (for example, 4294967295 which fits in `uint32` but not `int32`). We don't use the parallel `Long.parseUnsignedLong` because the existing code handles inputs like `"1.0"`. PiperOrigin-RevId: 723945649
- Loading branch information
1 parent
b8c3b60
commit aab6b1f
Showing
2 changed files
with
8 additions
and
28 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
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