top | item 40295289

(no title)

beautron | 1 year ago

This is a great analysis that gave me a lot to think about.

I've always loved the way Go's packages work. With care, I can organize large codebases that end up feeling so clean and nice to deal with.

I usually get to pick all my own package names, so the issues you bring up are manageable for me. But you explained them well, and I can imagine the frustration of inheriting public API packages that were not carefully designed.

And this one is a perennial little naming hiccup:

> Who among us hasn't wanted to shadow the name `url` or `path`?

I still prefer Go's packages to other languages' ways of code organization, but I think you convinced me that giving packages their own separator (and not sharing '.') might have been a better design. Though strangely, as you mentioned, any other separator is uglier.

discuss

order

No comments yet.