]> Cypherpunks repositories - gostls13.git/commit
encoding/hex: add NewEncoder, NewDecoder
authorTim Cooper <tim.cooper@layeh.com>
Thu, 12 Oct 2017 01:05:03 +0000 (22:05 -0300)
committerJoe Tsai <thebrokentoaster@gmail.com>
Fri, 20 Oct 2017 23:47:07 +0000 (23:47 +0000)
commit6db4950dc57deb899bf5550411c01ce32f16bdd0
tree11a16d2d68e4b82612cb7ffd6d78bf2d9a2c6718
parentd05f82a11af68a65b118de14bb230d640722d55c
encoding/hex: add NewEncoder, NewDecoder

NewEncoder returns an io.Writer that writes all incoming bytes as
hexadecimal characters to the underlying io.Writer. NewDecoder returns an
io.Reader that does the inverse.

Fixes #21590

Change-Id: Iebe0813faf365b42598f19a9aa41768f571dc0a8
Reviewed-on: https://go-review.googlesource.com/70210
Reviewed-by: Joe Tsai <thebrokentoaster@gmail.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/encoding/hex/hex.go
src/encoding/hex/hex_test.go