You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
this merely simplifies the interface a bit (no change in functionality) and makes further connection to the io package, which seems appropriate:
type File interface {
io.Closer
io.Reader
io.Seeker // ADD THIS
Readdir(count int) ([]os.FileInfo, error)
// Seek(offset int64, whence int) (int64, error) // REMOVE THIS
Stat() (os.FileInfo, error)
}
not sure if there are any policy reasons why this change couldn't be made, like strict api compatibility, etc.
The text was updated successfully, but these errors were encountered:
rakyll
changed the title
remove "Seek" from net/http.File interface, replace with "io.Seeker"
net/http: remove "Seek" from File interface, replace with "io.Seeker"
Nov 28, 2015
sounds good to me, i guess either io.ReadSeeker+io.Closer (your CL), or io.ReadCloser+io.Seeker could work? only reason i didn't suggest it at first, is for some reason io.Closer and io.Reader weren't already combined into io.ReadCloser. anyone out there know the reasoning, if any, around that?
this merely simplifies the interface a bit (no change in functionality) and makes further connection to the io package, which seems appropriate:
not sure if there are any policy reasons why this change couldn't be made, like strict api compatibility, etc.
The text was updated successfully, but these errors were encountered: