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
First off: This is a weird issue. I acknowledge that. But it messes with my personal workflow, so I'm curious whether it can be satisfactorily resolved.
Reproduce:
Clone toolchain to .../a; run .../a/make.bash
Ditto in .../b
cd .../b/src
Execute .../a/bin/go test bytes
Result:
go: reserved module path std not allow outside of GOROOT/src
There are three things going on here:
Grammatical error in error message.
Mysterious error message; it took me a while to realize the problem.
I don't see why this no longer works. Why must this be an error?
For context: When working on the compiler, I generally hang out in GOROOT/src. I use compilecmp to generate built toolchains with different versions. Then I refer to those versions by absolute path to run benchmarks.
This also sometimes happens under the hood. I already had to fix compilecmp because it could not be run from GOROOT/src because of the same issue.
It's an annoyance to have to cd around to run benchmarks, take care with what dir you're piping results to, etc.
Do you mean .../a/bin/go test ./bytes, with a ./? Because otherwise I'm not sure how that would work in the first place: the name bytes would be ambiguous.
If we have the invariant that the module std always refers to the standard library (and that its packages therefore always lack a prefix), then it's ambiguous because we don't know whether bytes refers to the std module in GOROOT, or to the std library in the current working directory.
On the other hand, if we treat a std module outside of GOROOT as just another module, perhaps that isn't a problem. (But it does mean that your workflow will break again if there is ever a standard subtree beginning with std/.)
First off: This is a weird issue. I acknowledge that. But it messes with my personal workflow, so I'm curious whether it can be satisfactorily resolved.
Reproduce:
.../a
; run.../a/make.bash
.../b
cd .../b/src
.../a/bin/go test bytes
Result:
go: reserved module path std not allow outside of GOROOT/src
There are three things going on here:
For context: When working on the compiler, I generally hang out in GOROOT/src. I use compilecmp to generate built toolchains with different versions. Then I refer to those versions by absolute path to run benchmarks.
This also sometimes happens under the hood. I already had to fix compilecmp because it could not be run from GOROOT/src because of the same issue.
It's an annoyance to have to
cd
around to run benchmarks, take care with what dir you're piping results to, etc.cc @bcmills @jayconrod
The text was updated successfully, but these errors were encountered: