Skip to content

Commit

Permalink
encoding/binary: add String and GoString method to nativeEndian
Browse files Browse the repository at this point in the history
Updates #57237

Change-Id: Ib626610130cae9c1d1aff5dd2a5035ffde0e127f
Reviewed-on: https://go-review.googlesource.com/c/go/+/463985
Reviewed-by: Ian Lance Taylor <[email protected]>
Run-TryBot: xie cui <[email protected]>
TryBot-Result: Gopher Robot <[email protected]>
Run-TryBot: Ian Lance Taylor <[email protected]>
Auto-Submit: Ian Lance Taylor <[email protected]>
Reviewed-by: Michael Knyszek <[email protected]>
  • Loading branch information
cuiweixie authored and gopherbot committed Jan 30, 2023
1 parent 4c5d979 commit 848d658
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/encoding/binary/binary.go
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,10 @@ func (bigEndian) String() string { return "BigEndian" }

func (bigEndian) GoString() string { return "binary.BigEndian" }

func (nativeEndian) String() string { return "NativeEndian" }

func (nativeEndian) GoString() string { return "binary.NativeEndian" }

// Read reads structured binary data from r into data.
// Data must be a pointer to a fixed-size value or a slice
// of fixed-size values.
Expand Down

0 comments on commit 848d658

Please sign in to comment.