Files
encoding/gob/encoding.go
andrey 3bb09b70d7
All checks were successful
Go Action / goaction (push) Successful in 33s
update lint and dependency (#2)
Reviewed-on: #2
2025-12-23 23:25:07 +03:00

22 lines
300 B
Go

package gob
import (
"encoding/gob"
"io"
"gitoa.ru/go-4devs/encoding"
)
var (
_ encoding.Decode = Decode
_ encoding.Encode = Encode
)
func Decode(r io.Reader, v any) error {
return gob.NewDecoder(r).Decode(v)
}
func Encode(w io.Writer, v any) error {
return gob.NewEncoder(w).Encode(v)
}