In golang's std package, "func decodeRuneInternal" and "func decodeRuneInStringInternal" are the same except the args, that is:
func decodeRuneInternal(p []byte) (r rune, size int, short bool)
func decodeRuneInStringInternal(s string) (r rune, size int, short bool)
Why not just define decodeRuneInStringInternal as:
func decodeRuneInStringInternal(s string) (r rune, size int, short bool) {
return decodeRuneInternal([]byte(s)) (r rune, size int, short bool)
}
in utf8.go, decodeRuneInStringInternal's implementations is the same with decodeRuneInternal.
WHY?