Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Kind of ironic for a language that was the first that I know about where you can straight up import libraries with a URL directly in your source.


It's not a URL, it's just an identifier that sort-of resembles a URL similar to Kubernetes annotation conventions.


It may not be quite a URL, but it contains the URL. It definitely more than just "sort-of resembles a URL". See how the module path to URL lookup is done here: https://go.dev/ref/mod#vcs-find


I understand your meaning, but that link supports my claims. The package path helps the Go tool infer the actual URL, but it doesn't contain the URL itself (e.g., the actual URL has a scheme/protocol component and potentially a `go-get=1` query string argument which don't exist as part of the path). This is what I meant when I said it "sort-of resembles a URL", but I understand from this conversation how that wording wasn't clear.


Fair. Strictly speaking it doesn't even "contain" a URL. But I think in the context of this conversation it acts like a URL -- it allows the Go tooling to fetch code from an arbitrary domain and path on the internet.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: