diff --git a/doc/go1.9.html b/doc/go1.9.html index 63e8b7a6d0..8f33a046d3 100644 --- a/doc/go1.9.html +++ b/doc/go1.9.html @@ -466,12 +466,9 @@ type T1 = T2 TODO: https://golang.org/cl/37260: allow Resolver to use a custom dialer
-- TODO: https://golang.org/cl/37402: implement deadline functionality on Pipe -
-
- TODO: https://golang.org/cl/40510: don't enclose non-literal IPv6 addresses in square brackets
+ JoinHostPort now only places an address in square brackets if the host contains a colon.
+ In previous releases it would also wrap addresses in square brackets if they contained a percent ('%') sign.
diff --git a/src/net/ipsock.go b/src/net/ipsock.go index 6049692d37..201c3f58bc 100644 --- a/src/net/ipsock.go +++ b/src/net/ipsock.go @@ -194,8 +194,8 @@ func splitHostZone(s string) (host, zone string) { } // JoinHostPort combines host and port into a network address of the -// form "host:port" or "host%zone:port", if host is a literal IPv6 -// address, "[host]:port" or [host%zone]:port. +// form "host:port". If host contains a colon, as found in literal +// IPv6 addresses, then JoinHostPort returns "[host]:port". func JoinHostPort(host, port string) string { // We assume that host is a literal IPv6 address if host has // colons.