diff --git a/README.md b/README.md index 06e8b0b7..9439f51b 100644 --- a/README.md +++ b/README.md @@ -208,6 +208,7 @@ Here are the Go packages that can be imported correctly: * [unicode/utf16](https://pkg.go.dev/unicode/utf16) * [math/bits](https://pkg.go.dev/math/bits) * [math](https://pkg.go.dev/math) +* [sync/atomic](https://pkg.go.dev/sync/atomic) (partially) ## How to install diff --git a/cl/compile.go b/cl/compile.go index d3dfe4ab..4b1e15b3 100644 --- a/cl/compile.go +++ b/cl/compile.go @@ -1019,6 +1019,8 @@ func NewPackageEx(prog llssa.Program, patches Patches, pkg *ssa.Package, files [ alt, hasPatch := patches[pkgPath] if hasPatch { pkgTypes = typepatch.Pkg(pkgTypes, alt.Pkg) + pkg.Pkg = pkgTypes + alt.Pkg = pkgTypes } if packages.DebugPackagesLoad { log.Println("==> NewPackageEx", pkgPath, hasPatch)