patch runtime, sync (use llgo:skipall)

This commit is contained in:
xushiwei
2024-06-16 23:07:42 +08:00
parent 9c8570b37d
commit df2f13c9b6
7 changed files with 96 additions and 17 deletions

View File

@@ -399,7 +399,7 @@ func buildPkg(prog llssa.Program, aPkg *aPackage, mode Mode, verbose bool) {
func canSkipToBuild(pkgPath string) bool {
switch pkgPath {
case "unsafe", "runtime", "errors", "sync":
case "unsafe", "errors":
return true
default:
return strings.HasPrefix(pkgPath, "internal/") ||
@@ -419,7 +419,9 @@ type none struct{}
var hasAltPkg = map[string]none{
"math": {},
"sync": {},
"sync/atomic": {},
"runtime": {},
}
type importer = func(pkgPath string) *packages.Package