| Server IP : 217.160.0.135 / Your IP : 216.73.217.85 Web Server : Apache System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64 User : sws1074145052 ( 1074145052) PHP Version : 8.3.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /lib/go-1.23/src/cmd/go/testdata/script/ |
Upload File : |
go list -e -deps -json=ImportPath,Error,DepsErrors m/a
cmp stdout want
-- want --
{
"ImportPath": "m/c",
"DepsErrors": [
{
"ImportStack": [
"m/a",
"m/b",
"m/c",
"m/a"
],
"Pos": "",
"Err": "import cycle not allowed"
}
]
}
{
"ImportPath": "m/b",
"DepsErrors": [
{
"ImportStack": [
"m/a",
"m/b",
"m/c",
"m/a"
],
"Pos": "",
"Err": "import cycle not allowed"
}
]
}
{
"ImportPath": "m/a",
"Error": {
"ImportStack": [
"m/a",
"m/b",
"m/c",
"m/a"
],
"Pos": "",
"Err": "import cycle not allowed"
},
"DepsErrors": [
{
"ImportStack": [
"m/a",
"m/b",
"m/c",
"m/a"
],
"Pos": "",
"Err": "import cycle not allowed"
}
]
}
-- go.mod --
module m
go 1.21
-- a/a.go --
package a
import _ "m/b"
-- b/b.go --
package b
import _ "m/c"
-- c/c.go --
package c
import _ "m/a"