From 3290fb870c1b48618f859153d8c0b76c5adb2dfc Mon Sep 17 00:00:00 2001 From: Than McIntosh Date: Wed, 8 Nov 2023 10:45:34 -0500 Subject: [PATCH] cmd/compile/internal/types: remove dead function Remove the function CleanroomDo, which is no longer being used anywhere. Change-Id: Ie148005793b004bf63ca996101d08c30b87f8575 Reviewed-on: https://go-review.googlesource.com/c/go/+/540776 Reviewed-by: Robert Griesemer LUCI-TryBot-Result: Go LUCI --- src/cmd/compile/internal/types/pkg.go | 9 --------- 1 file changed, 9 deletions(-) diff --git a/src/cmd/compile/internal/types/pkg.go b/src/cmd/compile/internal/types/pkg.go index 8223d801359..c6ce7889afb 100644 --- a/src/cmd/compile/internal/types/pkg.go +++ b/src/cmd/compile/internal/types/pkg.go @@ -129,12 +129,3 @@ func InternString(b []byte) string { internedStringsmu.Unlock() return s } - -// CleanroomDo invokes f in an environment with no preexisting packages. -// For testing of import/export only. -func CleanroomDo(f func()) { - saved := pkgMap - pkgMap = make(map[string]*Pkg) - f() - pkgMap = saved -}