1
0
Fork 0
mirror of https://github.com/sourcegraph/jsonrpc2.git synced 2026-08-17 02:28:13 +02:00

go: upgrade to Go 1.26.4 and run go fix ./...

This commit is contained in:
Geoffrey 2026-07-02 18:31:43 +00:00
parent 28070556df
commit 7293e9715b
No known key found for this signature in database
15 changed files with 57 additions and 64 deletions

View file

@ -21,12 +21,12 @@ func NewObjectStream(conn *ws.Conn) ObjectStream {
}
// WriteObject implements jsonrpc2.ObjectStream.
func (t ObjectStream) WriteObject(obj interface{}) error {
func (t ObjectStream) WriteObject(obj any) error {
return t.conn.WriteJSON(obj)
}
// ReadObject implements jsonrpc2.ObjectStream.
func (t ObjectStream) ReadObject(v interface{}) error {
func (t ObjectStream) ReadObject(v any) error {
err := t.conn.ReadJSON(v)
if e, ok := err.(*ws.CloseError); ok {
if e.Code == ws.CloseAbnormalClosure && e.Text == io.ErrUnexpectedEOF.Error() {