Standard library / compress/flate
compress/flate.ReadError
Deprecated wrapper containing Offset and underlying Err; modern readers do not normally return this type. Synthetic example only. Expected stdout: 'true\n'.
Formal Syntax & Structure
go syntaxgo
type ReadError struct { Offset int64 Err error}Working Example
Example Snippetgo
package main
import ( "compress/flate" "fmt" "io")
func must(e error) { if e != nil { panic(e) }}
func main() { var e error = &flate.ReadError{Offset: 4, Err: io.ErrUnexpectedEOF} fmt.Println(e.Error() != "")}