5 ms·
The canonical Go style eschews underscores in package names.
by tmhedberg 12y ago
The canonical Go style eschews underscores in package names.
- tptacek 12y agoIt seems like a superficial tabs-versus-spaces kind of point, but when you see how the standard library is organized and how package names interact with actual programs, you grok why underscores make people wince; "foo_bar" should either be "foo/bar", or just plain "bar". The import statement at the top of the file can clarify what the origin of a package is, but in the program body itself, the package name should make the library feel as natural as "fmt" or "io" or "math".