]> Cypherpunks repositories - gostls13.git/commit
fmt.Scan: fix %c in the case where the input does not implement ReadRune itself.
authorRob Pike <r@golang.org>
Wed, 16 Jun 2010 00:41:11 +0000 (17:41 -0700)
committerRob Pike <r@golang.org>
Wed, 16 Jun 2010 00:41:11 +0000 (17:41 -0700)
commitd60312c4c095004e0369f8aca03b2535f7db3758
treec324da46cfdf3a81799b92b146fa16bf2e294606
parent9baa7a51ba117205529b39c8ef738b9f373e5f37
fmt.Scan: fix %c in the case where the input does not implement ReadRune itself.
While we're at it, clean up and test the code to guarantee we see every byte when
the text is erroneous UTF-8.

Fixes #866.

R=rsc
CC=golang-dev
https://golang.org/cl/1712042
src/pkg/fmt/scan.go
src/pkg/fmt/scan_test.go