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
Yes but why the inconsistency. In ioutil it's under Variables. in io it's hidden as a comment under Writer. You have to already know Discard is a Writer to possibly even find it.
It doesn't even show up in the Index so it's hard to even find it.
Yes but why the inconsistency. In ioutil it's under Variables. in io it's hidden as a comment under Writer. You have to already know Discard is a Writer to possibly even find it.
I don't like it either, but i know the reason: It's because variables of a type defined in the same package are grouped with that type. Writer is defined in io, so Discard is grouped with it. ioutil does not define Writer, so the Discard variable there goes in the top section.
Uh oh!
There was an error while loading. Please reload this page.
What is the URL of the page with the issue?
https://pkg.go.dev/io
What is your user agent?
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/133.0.0.0 Safari/537.36
Screenshot
From ioutil docs:

From io docs:

What did you do?
N/A
What did you see happen?
N/A
What did you expect to see?
I expected to see
io.Discard
listed in variables sectionThe text was updated successfully, but these errors were encountered: