]> Cypherpunks repositories - gostls13.git/commitdiff
net/http: add link to types
authorabemotion <abemotion323@gmail.com>
Sat, 5 Apr 2025 01:40:06 +0000 (18:40 -0700)
committerGopher Robot <gobot@golang.org>
Mon, 7 Apr 2025 20:35:49 +0000 (13:35 -0700)
Some types are not linked.
This change adds a link to each type.

Change-Id: Id46fb64a74efb851ed76e4136f15e8fd9e445bb7
Reviewed-on: https://go-review.googlesource.com/c/go/+/663075
Reviewed-by: Damien Neil <dneil@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Auto-Submit: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Sean Liao <sean@liao.dev>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

src/net/http/client.go
src/net/http/request.go
src/net/http/responsecontroller.go

index 9231f63e65b134cf5302c66e59c7ae09c23db93f..a281a1ca6a95c838c1f46cc8b48550369f50e50d 100644 (file)
@@ -854,7 +854,7 @@ func Post(url, contentType string, body io.Reader) (resp *Response, err error) {
 // To make a request with a specified context.Context, use [NewRequestWithContext]
 // and [Client.Do].
 //
-// See the Client.Do method documentation for details on how redirects
+// See the [Client.Do] method documentation for details on how redirects
 // are handled.
 func (c *Client) Post(url, contentType string, body io.Reader) (resp *Response, err error) {
        req, err := NewRequest("POST", url, body)
@@ -894,7 +894,7 @@ func PostForm(url string, data url.Values) (resp *Response, err error) {
 // When err is nil, resp always contains a non-nil resp.Body.
 // Caller should close resp.Body when done reading from it.
 //
-// See the Client.Do method documentation for details on how redirects
+// See the [Client.Do] method documentation for details on how redirects
 // are handled.
 //
 // To make a request with a specified context.Context, use [NewRequestWithContext]
index 8a765c344245a6a6bb81651b5fc33aca3816c72a..167cff585af34a660aed36a395e8693b27b78086 100644 (file)
@@ -878,7 +878,7 @@ func NewRequest(method, url string, body io.Reader) (*Request, error) {
 // For an outgoing client request, the context
 // controls the entire lifetime of a request and its response:
 // obtaining a connection, sending the request, and reading the
-// response headers and body. See the Request type's documentation for
+// response headers and body. See the [Request] type's documentation for
 // the difference between inbound and outbound request fields.
 //
 // If body is of type [*bytes.Buffer], [*bytes.Reader], or
index f3f24c1273ee32092802d05374fdd07a06f83875..785fa21d17d45dba04411272fd05a4bc5490397b 100644 (file)
@@ -62,7 +62,7 @@ func (c *ResponseController) Flush() error {
 }
 
 // Hijack lets the caller take over the connection.
-// See the Hijacker interface for details.
+// See the [Hijacker] interface for details.
 func (c *ResponseController) Hijack() (net.Conn, *bufio.ReadWriter, error) {
        rw := c.rw
        for {