mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
net/http: remove unused linknames
These were removed in:
8e2d520ba2
For #67401
Change-Id: I44898beb6fa3b6867b3d2164fc930724e143cf30
Reviewed-on: https://go-review.googlesource.com/c/go/+/721200
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Damien Neil <dneil@google.com>
Reviewed-by: Mark Freeman <markfreeman@google.com>
This commit is contained in:
parent
0f32fbc631
commit
65ef314f89
1 changed files with 0 additions and 36 deletions
|
|
@ -854,15 +854,6 @@ func bufioWriterPool(size int) *sync.Pool {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// newBufioReader should be an internal detail,
|
|
||||||
// but widely used packages access it using linkname.
|
|
||||||
// Notable members of the hall of shame include:
|
|
||||||
// - github.com/gobwas/ws
|
|
||||||
//
|
|
||||||
// Do not remove or change the type signature.
|
|
||||||
// See go.dev/issue/67401.
|
|
||||||
//
|
|
||||||
//go:linkname newBufioReader
|
|
||||||
func newBufioReader(r io.Reader) *bufio.Reader {
|
func newBufioReader(r io.Reader) *bufio.Reader {
|
||||||
if v := bufioReaderPool.Get(); v != nil {
|
if v := bufioReaderPool.Get(); v != nil {
|
||||||
br := v.(*bufio.Reader)
|
br := v.(*bufio.Reader)
|
||||||
|
|
@ -874,29 +865,11 @@ func newBufioReader(r io.Reader) *bufio.Reader {
|
||||||
return bufio.NewReader(r)
|
return bufio.NewReader(r)
|
||||||
}
|
}
|
||||||
|
|
||||||
// putBufioReader should be an internal detail,
|
|
||||||
// but widely used packages access it using linkname.
|
|
||||||
// Notable members of the hall of shame include:
|
|
||||||
// - github.com/gobwas/ws
|
|
||||||
//
|
|
||||||
// Do not remove or change the type signature.
|
|
||||||
// See go.dev/issue/67401.
|
|
||||||
//
|
|
||||||
//go:linkname putBufioReader
|
|
||||||
func putBufioReader(br *bufio.Reader) {
|
func putBufioReader(br *bufio.Reader) {
|
||||||
br.Reset(nil)
|
br.Reset(nil)
|
||||||
bufioReaderPool.Put(br)
|
bufioReaderPool.Put(br)
|
||||||
}
|
}
|
||||||
|
|
||||||
// newBufioWriterSize should be an internal detail,
|
|
||||||
// but widely used packages access it using linkname.
|
|
||||||
// Notable members of the hall of shame include:
|
|
||||||
// - github.com/gobwas/ws
|
|
||||||
//
|
|
||||||
// Do not remove or change the type signature.
|
|
||||||
// See go.dev/issue/67401.
|
|
||||||
//
|
|
||||||
//go:linkname newBufioWriterSize
|
|
||||||
func newBufioWriterSize(w io.Writer, size int) *bufio.Writer {
|
func newBufioWriterSize(w io.Writer, size int) *bufio.Writer {
|
||||||
pool := bufioWriterPool(size)
|
pool := bufioWriterPool(size)
|
||||||
if pool != nil {
|
if pool != nil {
|
||||||
|
|
@ -909,15 +882,6 @@ func newBufioWriterSize(w io.Writer, size int) *bufio.Writer {
|
||||||
return bufio.NewWriterSize(w, size)
|
return bufio.NewWriterSize(w, size)
|
||||||
}
|
}
|
||||||
|
|
||||||
// putBufioWriter should be an internal detail,
|
|
||||||
// but widely used packages access it using linkname.
|
|
||||||
// Notable members of the hall of shame include:
|
|
||||||
// - github.com/gobwas/ws
|
|
||||||
//
|
|
||||||
// Do not remove or change the type signature.
|
|
||||||
// See go.dev/issue/67401.
|
|
||||||
//
|
|
||||||
//go:linkname putBufioWriter
|
|
||||||
func putBufioWriter(bw *bufio.Writer) {
|
func putBufioWriter(bw *bufio.Writer) {
|
||||||
bw.Reset(nil)
|
bw.Reset(nil)
|
||||||
if pool := bufioWriterPool(bw.Available()); pool != nil {
|
if pool := bufioWriterPool(bw.Available()); pool != nil {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue