Re: [go-nuts] Re: How can stop a Read of net.Conn without closing it

2020-05-10 Thread hanisch
On Wednesday, June 5, 2019 at 10:14:22 AM UTC-4, Ian Lance Taylor wrote: > > On Wed, Jun 5, 2019 at 12:10 AM Kurtis Rader > wrote: > > > > On Tue, Jun 4, 2019 at 11:53 PM Inada Naoki > wrote: > >> > >> conn.SetReadDeadline(time.Now()) > > > > > > Did you test that solution? Setting a

[go-nuts] Re: whenceReader

2019-12-08 Thread hanisch
The type definition above should read: type whenceReader struct { rio.ReaderAt off int64 } (I forgot to put the package name (i.e., "io." in front of ReaderAt.) On Sunday, December 8, 2019 at 6:19:04 PM UTC-5, William Hanisch wrote: > > Suppose yo

[go-nuts] whenceReader

2019-12-08 Thread hanisch
Suppose you (okay, okay, I) want something like an io.SectionReader but don't want to specify the end point of the section, just the start. That is, method calls to Read should only return EOF when at the end of the underlying source of the initially supplied io.ReaderAt. This can be

[go-nuts] Re: Listing of names on https://golang.org/pkg/

2018-03-29 Thread hanisch
I opened issue number 24601 for this. You can see it here: https://github.com/golang/go/issues/24601 William On Thursday, March 29, 2018 at 5:22:54 PM UTC-4, William Hanisch wrote: > > I don't know if this is related to 1.10.1 or not--I just noticed it > today--but if you go

Re: [go-nuts] Listing of names on https://golang.org/pkg/

2018-03-29 Thread William Hanisch
Yes! I see it both on https://golang.org/pkg/ (where is says "Build version go1.10.1.” near the very bottom of the page), as well as https://tip.golang.org/pkg/ (where is says “Build version devel +64bf90576e Thu Mar 29 20:51:13 2018 +.” near the bottom). If I wait a few minutes and

[go-nuts] Listing of names on https://golang.org/pkg/

2018-03-29 Thread hanisch
I don't know if this is related to 1.10.1 or not--I just noticed it today--but if you go to https://golang.org/pkg/ the "Names" column for the packages is no longer completely in alphabetical order. It seems like the package names (or rather import names) are broken into two groups. Within

[go-nuts] shiny driver.Main not returning

2017-09-07 Thread hanisch
I'm using shiny for a small internal project and noticed that driver.Main doesn't seem to return. The documentation for: func Main(f func(screen . Screen )) in golang.org/x/exp/shiny/driver

[go-nuts] log package implementation question

2017-06-07 Thread hanisch
I was perusing the code for the standard log package (src/log/log.go - The Go Programming Language ) and was wondering why the formatHeader method (line 92) takes a pointer to byte slice since the only call to this method line (163) calls it

[go-nuts] encoding.BinaryMarshaler interface

2017-01-11 Thread hanisch
Suppose there's a struct, say Foo, that needs to be serialized and sent over the network very frequently (about every 100 microseconds to one millisecond, to a multicast group). To serialize Foo to write it to an io.Writer (e.g., a net.UDPConn), it would think it would be nice to have Foo