diff -urN b/benchmark/parse/BUILD.bazel c/benchmark/parse/BUILD.bazel
--- b/benchmark/parse/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/benchmark/parse/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "parse",
+    srcs = ["parse.go"],
+    importpath = "golang.org/x/tools/benchmark/parse",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":parse",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "parse_test",
+    srcs = ["parse_test.go"],
+    embed = [":parse"],
+)
diff -urN b/blog/atom/BUILD.bazel c/blog/atom/BUILD.bazel
--- b/blog/atom/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/blog/atom/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "atom",
+    srcs = ["atom.go"],
+    importpath = "golang.org/x/tools/blog/atom",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":atom",
+    visibility = ["//visibility:public"],
+)
diff -urN b/blog/BUILD.bazel c/blog/BUILD.bazel
--- b/blog/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/blog/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "blog",
+    srcs = ["blog.go"],
+    importpath = "golang.org/x/tools/blog",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//blog/atom",
+        "//present",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":blog",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "blog_test",
+    srcs = ["blog_test.go"],
+    embed = [":blog"],
+)
diff -urN b/cmd/auth/authtest/BUILD.bazel c/cmd/auth/authtest/BUILD.bazel
--- b/cmd/auth/authtest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/auth/authtest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "authtest_lib",
+    srcs = ["authtest.go"],
+    importpath = "golang.org/x/tools/cmd/auth/authtest",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "authtest",
+    embed = [":authtest_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/auth/cookieauth/BUILD.bazel c/cmd/auth/cookieauth/BUILD.bazel
--- b/cmd/auth/cookieauth/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/auth/cookieauth/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "cookieauth_lib",
+    srcs = ["cookieauth.go"],
+    importpath = "golang.org/x/tools/cmd/auth/cookieauth",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "cookieauth",
+    embed = [":cookieauth_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/auth/gitauth/BUILD.bazel c/cmd/auth/gitauth/BUILD.bazel
--- b/cmd/auth/gitauth/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/auth/gitauth/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "gitauth_lib",
+    srcs = ["gitauth.go"],
+    importpath = "golang.org/x/tools/cmd/auth/gitauth",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "gitauth",
+    embed = [":gitauth_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/auth/netrcauth/BUILD.bazel c/cmd/auth/netrcauth/BUILD.bazel
--- b/cmd/auth/netrcauth/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/auth/netrcauth/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "netrcauth_lib",
+    srcs = ["netrcauth.go"],
+    importpath = "golang.org/x/tools/cmd/auth/netrcauth",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "netrcauth",
+    embed = [":netrcauth_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/benchcmp/BUILD.bazel c/cmd/benchcmp/BUILD.bazel
--- b/cmd/benchcmp/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/benchcmp/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "benchcmp_lib",
+    srcs = [
+        "benchcmp.go",
+        "compare.go",
+        "doc.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/benchcmp",
+    visibility = ["//visibility:private"],
+    deps = ["//benchmark/parse"],
+)
+
+go_binary(
+    name = "benchcmp",
+    embed = [":benchcmp_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "benchcmp_test",
+    srcs = [
+        "benchcmp_test.go",
+        "compare_test.go",
+    ],
+    embed = [":benchcmp_lib"],
+    deps = ["//benchmark/parse"],
+)
diff -urN b/cmd/bisect/BUILD.bazel c/cmd/bisect/BUILD.bazel
--- b/cmd/bisect/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/bisect/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "bisect_lib",
+    srcs = [
+        "go120.go",
+        "main.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/bisect",
+    visibility = ["//visibility:private"],
+    deps = ["//internal/bisect"],
+)
+
+go_binary(
+    name = "bisect",
+    embed = [":bisect_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "bisect_test",
+    srcs = ["main_test.go"],
+    data = glob(["testdata/**"]),
+    embed = [":bisect_lib"],
+    deps = [
+        "//internal/bisect",
+        "//internal/diffp",
+        "//txtar",
+    ],
+)
diff -urN b/cmd/bundle/BUILD.bazel c/cmd/bundle/BUILD.bazel
--- b/cmd/bundle/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/bundle/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "bundle_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/bundle",
+    visibility = ["//visibility:private"],
+    deps = ["//go/packages"],
+)
+
+go_binary(
+    name = "bundle",
+    embed = [":bundle_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "bundle_test",
+    srcs = ["main_test.go"],
+    embed = [":bundle_lib"],
+    deps = ["//internal/packagestest"],
+)
diff -urN b/cmd/bundle/testdata/src/domain.name/importdecl/BUILD.bazel c/cmd/bundle/testdata/src/domain.name/importdecl/BUILD.bazel
--- b/cmd/bundle/testdata/src/domain.name/importdecl/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/bundle/testdata/src/domain.name/importdecl/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "importdecl",
+    srcs = ["p.go"],
+    importpath = "golang.org/x/tools/cmd/bundle/testdata/src/domain.name/importdecl",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":importdecl",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/bundle/testdata/src/initial/BUILD.bazel c/cmd/bundle/testdata/src/initial/BUILD.bazel
--- b/cmd/bundle/testdata/src/initial/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/bundle/testdata/src/initial/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "initial",
+    srcs = [
+        "a.go",
+        "b.go",
+        "c.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/bundle/testdata/src/initial",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":initial",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/callgraph/BUILD.bazel c/cmd/callgraph/BUILD.bazel
--- b/cmd/callgraph/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/callgraph/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,72 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "callgraph_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/callgraph",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/callgraph",
+        "//go/callgraph/cha",
+        "//go/callgraph/rta",
+        "//go/callgraph/static",
+        "//go/callgraph/vta",
+        "//go/packages",
+        "//go/ssa",
+        "//go/ssa/ssautil",
+    ],
+)
+
+go_binary(
+    name = "callgraph",
+    embed = [":callgraph_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "callgraph_test",
+    srcs = ["main_test.go"],
+    embed = [":callgraph_lib"],
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            "//internal/testenv",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/cmd/callgraph/testdata/src/pkg/BUILD.bazel c/cmd/callgraph/testdata/src/pkg/BUILD.bazel
--- b/cmd/callgraph/testdata/src/pkg/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/callgraph/testdata/src/pkg/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "pkg_lib",
+    srcs = ["pkg.go"],
+    importpath = "golang.org/x/tools/cmd/callgraph/testdata/src/pkg",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "pkg",
+    embed = [":pkg_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "pkg_test",
+    srcs = ["pkg_test.go"],
+    embed = [":pkg_lib"],
+)
diff -urN b/cmd/compilebench/BUILD.bazel c/cmd/compilebench/BUILD.bazel
--- b/cmd/compilebench/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/compilebench/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "compilebench_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/compilebench",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "compilebench",
+    embed = [":compilebench_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/deadcode/BUILD.bazel c/cmd/deadcode/BUILD.bazel
--- b/cmd/deadcode/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/deadcode/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,37 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "deadcode_lib",
+    srcs = [
+        "deadcode.go",
+        "doc.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/cmd/deadcode",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/callgraph",
+        "//go/callgraph/rta",
+        "//go/packages",
+        "//go/ssa",
+        "//go/ssa/ssautil",
+        "//internal/typesinternal",
+        "@org_golang_x_telemetry//:go_default_library",
+    ],
+)
+
+go_binary(
+    name = "deadcode",
+    embed = [":deadcode_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "deadcode_test",
+    srcs = ["deadcode_test.go"],
+    data = glob(["testdata/**"]),
+    deps = [
+        "//internal/testenv",
+        "//txtar",
+    ],
+)
diff -urN b/cmd/digraph/BUILD.bazel c/cmd/digraph/BUILD.bazel
--- b/cmd/digraph/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/digraph/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "digraph_lib",
+    srcs = [
+        "digraph.go",
+        "doc.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/cmd/digraph",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "digraph",
+    embed = [":digraph_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "digraph_test",
+    srcs = ["digraph_test.go"],
+    embed = [":digraph_lib"],
+)
diff -urN b/cmd/eg/BUILD.bazel c/cmd/eg/BUILD.bazel
--- b/cmd/eg/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/eg/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "eg_lib",
+    srcs = ["eg.go"],
+    importpath = "golang.org/x/tools/cmd/eg",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/packages",
+        "//refactor/eg",
+    ],
+)
+
+go_binary(
+    name = "eg",
+    embed = [":eg_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/file2fuzz/BUILD.bazel c/cmd/file2fuzz/BUILD.bazel
--- b/cmd/file2fuzz/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/file2fuzz/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,21 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "file2fuzz_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/file2fuzz",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "file2fuzz",
+    embed = [":file2fuzz_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "file2fuzz_test",
+    srcs = ["main_test.go"],
+    embed = [":file2fuzz_lib"],
+    deps = ["//internal/testenv"],
+)
diff -urN b/cmd/fiximports/BUILD.bazel c/cmd/fiximports/BUILD.bazel
--- b/cmd/fiximports/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,62 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "fiximports_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "fiximports",
+    embed = [":fiximports_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "fiximports_test",
+    srcs = ["main_test.go"],
+    embed = [":fiximports_lib"],
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            "//internal/testenv",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            "//internal/testenv",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/cmd/fiximports/testdata/src/fruit.io/banana/BUILD.bazel c/cmd/fiximports/testdata/src/fruit.io/banana/BUILD.bazel
--- b/cmd/fiximports/testdata/src/fruit.io/banana/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/fruit.io/banana/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "banana",
+    srcs = ["banana.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/fruit.io/banana",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":banana",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/fiximports/testdata/src/fruit.io/orange/BUILD.bazel c/cmd/fiximports/testdata/src/fruit.io/orange/BUILD.bazel
--- b/cmd/fiximports/testdata/src/fruit.io/orange/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/fruit.io/orange/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "orange",
+    srcs = ["orange.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/fruit.io/orange",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":orange",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/fiximports/testdata/src/fruit.io/pear/BUILD.bazel c/cmd/fiximports/testdata/src/fruit.io/pear/BUILD.bazel
--- b/cmd/fiximports/testdata/src/fruit.io/pear/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/fruit.io/pear/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "pear",
+    srcs = ["pear.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/fruit.io/pear",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":pear",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/fiximports/testdata/src/new.com/one/BUILD.bazel c/cmd/fiximports/testdata/src/new.com/one/BUILD.bazel
--- b/cmd/fiximports/testdata/src/new.com/one/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/new.com/one/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "one",
+    srcs = ["one.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/new.com/one",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":one",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/fiximports/testdata/src/old.com/bad/BUILD.bazel c/cmd/fiximports/testdata/src/old.com/bad/BUILD.bazel
--- b/cmd/fiximports/testdata/src/old.com/bad/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/old.com/bad/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "bad",
+    srcs = ["bad.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/old.com/bad",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":bad",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/fiximports/testdata/src/old.com/one/BUILD.bazel c/cmd/fiximports/testdata/src/old.com/one/BUILD.bazel
--- b/cmd/fiximports/testdata/src/old.com/one/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/old.com/one/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "one",
+    srcs = ["one.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/old.com/one",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":one",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/fiximports/testdata/src/titanic.biz/bar/BUILD.bazel c/cmd/fiximports/testdata/src/titanic.biz/bar/BUILD.bazel
--- b/cmd/fiximports/testdata/src/titanic.biz/bar/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/titanic.biz/bar/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "bar",
+    srcs = ["bar.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/titanic.biz/bar",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":bar",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/fiximports/testdata/src/titanic.biz/foo/BUILD.bazel c/cmd/fiximports/testdata/src/titanic.biz/foo/BUILD.bazel
--- b/cmd/fiximports/testdata/src/titanic.biz/foo/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/fiximports/testdata/src/titanic.biz/foo/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "foo",
+    srcs = ["foo.go"],
+    importpath = "golang.org/x/tools/cmd/fiximports/testdata/src/titanic.biz/foo",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":foo",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/go-contrib-init/BUILD.bazel c/cmd/go-contrib-init/BUILD.bazel
--- b/cmd/go-contrib-init/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/go-contrib-init/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "go-contrib-init_lib",
+    srcs = ["contrib.go"],
+    importpath = "golang.org/x/tools/cmd/go-contrib-init",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "go-contrib-init",
+    embed = [":go-contrib-init_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "go-contrib-init_test",
+    srcs = ["contrib_test.go"],
+    embed = [":go-contrib-init_lib"],
+)
diff -urN b/cmd/godex/BUILD.bazel c/cmd/godex/BUILD.bazel
--- b/cmd/godex/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/godex/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "godex_lib",
+    srcs = [
+        "doc.go",
+        "gc.go",
+        "gccgo.go",
+        "godex.go",
+        "isAlias18.go",
+        "isAlias19.go",
+        "print.go",
+        "source.go",
+        "writetype.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/godex",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "godex",
+    embed = [":godex_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/goimports/BUILD.bazel c/cmd/goimports/BUILD.bazel
--- b/cmd/goimports/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/goimports/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,23 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "goimports_lib",
+    srcs = [
+        "doc.go",
+        "goimports.go",
+        "goimports_gc.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/goimports",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//internal/gocommand",
+        "//internal/imports",
+        "@org_golang_x_telemetry//counter:go_default_library",
+    ],
+)
+
+go_binary(
+    name = "goimports",
+    embed = [":goimports_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/gomvpkg/BUILD.bazel c/cmd/gomvpkg/BUILD.bazel
--- b/cmd/gomvpkg/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/gomvpkg/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "gomvpkg_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/gomvpkg",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/buildutil",
+        "//refactor/rename",
+    ],
+)
+
+go_binary(
+    name = "gomvpkg",
+    embed = [":gomvpkg_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/gonew/BUILD.bazel c/cmd/gonew/BUILD.bazel
--- b/cmd/gonew/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/gonew/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,31 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "gonew_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/gonew",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//internal/edit",
+        "@org_golang_x_mod//modfile:go_default_library",
+        "@org_golang_x_mod//module:go_default_library",
+    ],
+)
+
+go_binary(
+    name = "gonew",
+    embed = [":gonew_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "gonew_test",
+    srcs = ["main_test.go"],
+    data = glob(["testdata/**"]),
+    embed = [":gonew_lib"],
+    deps = [
+        "//internal/diffp",
+        "//internal/testenv",
+        "//txtar",
+    ],
+)
diff -urN b/cmd/gotype/BUILD.bazel c/cmd/gotype/BUILD.bazel
--- b/cmd/gotype/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/gotype/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "gotype_lib",
+    srcs = [
+        "gotype.go",
+        "sizesFor18.go",
+        "sizesFor19.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/gotype",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "gotype",
+    embed = [":gotype_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/goyacc/BUILD.bazel c/cmd/goyacc/BUILD.bazel
--- b/cmd/goyacc/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/goyacc/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "goyacc_lib",
+    srcs = [
+        "doc.go",
+        "yacc.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/goyacc",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "goyacc",
+    embed = [":goyacc_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/goyacc/testdata/expr/BUILD.bazel c/cmd/goyacc/testdata/expr/BUILD.bazel
--- b/cmd/goyacc/testdata/expr/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/goyacc/testdata/expr/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "expr_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/goyacc/testdata/expr",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":expr_lib",
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/html2article/BUILD.bazel c/cmd/html2article/BUILD.bazel
--- b/cmd/html2article/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/html2article/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "html2article_lib",
+    srcs = ["conv.go"],
+    importpath = "golang.org/x/tools/cmd/html2article",
+    visibility = ["//visibility:private"],
+    deps = [
+        "@org_golang_x_net//html:go_default_library",
+        "@org_golang_x_net//html/atom:go_default_library",
+    ],
+)
+
+go_binary(
+    name = "html2article",
+    embed = [":html2article_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/present/BUILD.bazel c/cmd/present/BUILD.bazel
--- b/cmd/present/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/present/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,42 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "present_lib",
+    srcs = [
+        "dir.go",
+        "doc.go",
+        "main.go",
+        "play.go",
+    ],
+    embedsrcs = [
+        "static/article.css",
+        "static/dir.css",
+        "static/dir.js",
+        "static/favicon.ico",
+        "static/jquery-ui.js",
+        "static/jquery.js",
+        "static/notes.css",
+        "static/notes.js",
+        "static/play.js",
+        "static/playground.js",
+        "static/slides.js",
+        "static/styles.css",
+        "templates/action.tmpl",
+        "templates/article.tmpl",
+        "templates/dir.tmpl",
+        "templates/slides.tmpl",
+    ],
+    importpath = "golang.org/x/tools/cmd/present",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//playground",
+        "//playground/socket",
+        "//present",
+    ],
+)
+
+go_binary(
+    name = "present",
+    embed = [":present_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/present2md/BUILD.bazel c/cmd/present2md/BUILD.bazel
--- b/cmd/present2md/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/present2md/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "present2md_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/present2md",
+    visibility = ["//visibility:private"],
+    deps = ["//present"],
+)
+
+go_binary(
+    name = "present2md",
+    embed = [":present2md_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/signature-fuzzer/fuzz-driver/BUILD.bazel c/cmd/signature-fuzzer/fuzz-driver/BUILD.bazel
--- b/cmd/signature-fuzzer/fuzz-driver/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/signature-fuzzer/fuzz-driver/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "fuzz-driver_lib",
+    srcs = ["driver.go"],
+    importpath = "golang.org/x/tools/cmd/signature-fuzzer/fuzz-driver",
+    visibility = ["//visibility:private"],
+    deps = ["//cmd/signature-fuzzer/internal/fuzz-generator"],
+)
+
+go_binary(
+    name = "fuzz-driver",
+    embed = [":fuzz-driver_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "fuzz-driver_test",
+    srcs = ["drv_test.go"],
+    embed = [":fuzz-driver_lib"],
+    deps = ["//internal/testenv"],
+)
diff -urN b/cmd/signature-fuzzer/fuzz-runner/BUILD.bazel c/cmd/signature-fuzzer/fuzz-runner/BUILD.bazel
--- b/cmd/signature-fuzzer/fuzz-runner/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/signature-fuzzer/fuzz-runner/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "fuzz-runner_lib",
+    srcs = ["runner.go"],
+    importpath = "golang.org/x/tools/cmd/signature-fuzzer/fuzz-runner",
+    visibility = ["//visibility:private"],
+    deps = ["//cmd/signature-fuzzer/internal/fuzz-generator"],
+)
+
+go_binary(
+    name = "fuzz-runner",
+    embed = [":fuzz-runner_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "fuzz-runner_test",
+    srcs = ["rnr_test.go"],
+    embed = [":fuzz-runner_lib"],
+    deps = ["//internal/testenv"],
+)
diff -urN b/cmd/signature-fuzzer/fuzz-runner/testdata/BUILD.bazel c/cmd/signature-fuzzer/fuzz-runner/testdata/BUILD.bazel
--- b/cmd/signature-fuzzer/fuzz-runner/testdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/signature-fuzzer/fuzz-runner/testdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "testdata_lib",
+    srcs = ["himom.go"],
+    importpath = "golang.org/x/tools/cmd/signature-fuzzer/fuzz-runner/testdata",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "testdata",
+    embed = [":testdata_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/signature-fuzzer/internal/fuzz-generator/BUILD.bazel c/cmd/signature-fuzzer/internal/fuzz-generator/BUILD.bazel
--- b/cmd/signature-fuzzer/internal/fuzz-generator/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/signature-fuzzer/internal/fuzz-generator/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,32 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "fuzz-generator",
+    srcs = [
+        "arrayparm.go",
+        "generator.go",
+        "mapparm.go",
+        "numparm.go",
+        "parm.go",
+        "pointerparm.go",
+        "stringparm.go",
+        "structparm.go",
+        "typedefparm.go",
+        "wraprand.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/signature-fuzzer/internal/fuzz-generator",
+    visibility = ["//cmd/signature-fuzzer:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fuzz-generator",
+    visibility = ["//cmd/signature-fuzzer:__subpackages__"],
+)
+
+go_test(
+    name = "fuzz-generator_test",
+    srcs = ["gen_test.go"],
+    embed = [":fuzz-generator"],
+    deps = ["//internal/testenv"],
+)
diff -urN b/cmd/splitdwarf/BUILD.bazel c/cmd/splitdwarf/BUILD.bazel
--- b/cmd/splitdwarf/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/splitdwarf/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,44 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "splitdwarf_lib",
+    srcs = ["splitdwarf.go"],
+    importpath = "golang.org/x/tools/cmd/splitdwarf",
+    visibility = ["//visibility:private"],
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:android": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            "//cmd/splitdwarf/internal/macho",
+        ],
+        "//conditions:default": [],
+    }),
+)
+
+go_binary(
+    name = "splitdwarf",
+    embed = [":splitdwarf_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/splitdwarf/internal/macho/BUILD.bazel c/cmd/splitdwarf/internal/macho/BUILD.bazel
--- b/cmd/splitdwarf/internal/macho/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/splitdwarf/internal/macho/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "macho",
+    srcs = [
+        "fat.go",
+        "file.go",
+        "macho.go",
+        "reloctype.go",
+        "reloctype_string.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/splitdwarf/internal/macho",
+    visibility = ["//cmd/splitdwarf:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":macho",
+    visibility = ["//cmd/splitdwarf:__subpackages__"],
+)
+
+go_test(
+    name = "macho_test",
+    srcs = ["file_test.go"],
+    data = glob(["testdata/**"]),
+    embed = [":macho"],
+)
diff -urN b/cmd/ssadump/BUILD.bazel c/cmd/ssadump/BUILD.bazel
--- b/cmd/ssadump/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/ssadump/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "ssadump_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/cmd/ssadump",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/packages",
+        "//go/ssa",
+        "//go/ssa/interp",
+        "//go/ssa/ssautil",
+    ],
+)
+
+go_binary(
+    name = "ssadump",
+    embed = [":ssadump_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/stress/BUILD.bazel c/cmd/stress/BUILD.bazel
--- b/cmd/stress/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/stress/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "stress_lib",
+    srcs = ["stress.go"],
+    importpath = "golang.org/x/tools/cmd/stress",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "stress",
+    embed = [":stress_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/stringer/BUILD.bazel c/cmd/stringer/BUILD.bazel
--- b/cmd/stringer/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/stringer/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,83 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
+
+go_library(
+    name = "stringer_lib",
+    srcs = ["stringer.go"],
+    importpath = "golang.org/x/tools/cmd/stringer",
+    visibility = ["//visibility:private"],
+    deps = ["//go/packages"],
+)
+
+go_binary(
+    name = "stringer",
+    embed = [":stringer_lib"],
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "stringer_test",
+    srcs = [
+        "endtoend_test.go",
+        "golden_test.go",
+        "multifile_test.go",
+        "util_test.go",
+    ],
+    embed = [":stringer_lib"],
+    deps = [
+        "//internal/testenv",
+    ] + select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            "//internal/diffp",
+            "//txtar",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/cmd/stringer/testdata/BUILD.bazel c/cmd/stringer/testdata/BUILD.bazel
--- b/cmd/stringer/testdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/stringer/testdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "testdata_lib",
+    srcs = [
+        "cgo.go",
+        "conv.go",
+        "conv2.go",
+        "day.go",
+        "gap.go",
+        "int8overflow.go",
+        "num.go",
+        "number.go",
+        "prime.go",
+        "prime2.go",
+        "tag_main.go",
+        "unum.go",
+        "unum2.go",
+        "vary_day.go",
+    ],
+    cgo = True,
+    importpath = "golang.org/x/tools/cmd/stringer/testdata",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "testdata",
+    embed = [":testdata_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/cmd/toolstash/BUILD.bazel c/cmd/toolstash/BUILD.bazel
--- b/cmd/toolstash/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cmd/toolstash/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "toolstash_lib",
+    srcs = [
+        "cmp.go",
+        "main.go",
+    ],
+    importpath = "golang.org/x/tools/cmd/toolstash",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "toolstash",
+    embed = [":toolstash_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/container/intsets/BUILD.bazel c/container/intsets/BUILD.bazel
--- b/container/intsets/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/container/intsets/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,23 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "intsets",
+    srcs = ["sparse.go"],
+    importpath = "golang.org/x/tools/container/intsets",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":intsets",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "intsets_test",
+    srcs = [
+        "export_test.go",
+        "sparse_test.go",
+    ],
+    embed = [":intsets"],
+)
diff -urN b/copyright/BUILD.bazel c/copyright/BUILD.bazel
--- b/copyright/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/copyright/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "copyright",
+    srcs = ["copyright.go"],
+    importpath = "golang.org/x/tools/copyright",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":copyright",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "copyright_test",
+    srcs = ["copyright_test.go"],
+    embed = [":copyright"],
+)
diff -urN b/cover/BUILD.bazel c/cover/BUILD.bazel
--- b/cover/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/cover/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "cover",
+    srcs = ["profile.go"],
+    importpath = "golang.org/x/tools/cover",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":cover",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "cover_test",
+    srcs = ["profile_test.go"],
+    embed = [":cover"],
+)
diff -urN b/go/analysis/analysistest/BUILD.bazel c/go/analysis/analysistest/BUILD.bazel
--- b/go/analysis/analysistest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/analysistest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "analysistest",
+    srcs = ["analysistest.go"],
+    importpath = "golang.org/x/tools/go/analysis/analysistest",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/checker",
+        "//go/analysis/internal",
+        "//go/packages",
+        "//internal/diff",
+        "//internal/testenv",
+        "//txtar",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":analysistest",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "analysistest_test",
+    srcs = ["analysistest_test.go"],
+    deps = [
+        ":analysistest",
+        "//go/analysis",
+        "//go/analysis/passes/findcall",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/go/analysis/BUILD.bazel c/go/analysis/BUILD.bazel
--- b/go/analysis/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,25 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "analysis",
+    srcs = [
+        "analysis.go",
+        "diagnostic.go",
+        "doc.go",
+        "validate.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":analysis",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "analysis_test",
+    srcs = ["validate_test.go"],
+    embed = [":analysis"],
+)
diff -urN b/go/analysis/checker/BUILD.bazel c/go/analysis/checker/BUILD.bazel
--- b/go/analysis/checker/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/checker/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,104 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "checker",
+    srcs = [
+        "checker.go",
+        "print.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/checker",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/internal",
+        "//go/analysis/internal/analysisflags",
+        "//go/packages",
+        "//internal/analysisinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":checker",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "checker_test",
+    srcs = ["example_test.go"],
+    deps = select({
+        "@io_bazel_rules_go//go/platform:386": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:amd64": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:arm": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:arm64": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:mips": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:mips64": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:mips64le": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:mipsle": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:ppc64": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:ppc64le": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:riscv64": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:s390x": [
+            ":checker",
+            "//go/analysis",
+            "//go/packages",
+            "//txtar",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/go/analysis/internal/analysisflags/BUILD.bazel c/go/analysis/internal/analysisflags/BUILD.bazel
--- b/go/analysis/internal/analysisflags/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/internal/analysisflags/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "analysisflags",
+    srcs = [
+        "fix.go",
+        "flags.go",
+        "help.go",
+        "url.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/internal/analysisflags",
+    visibility = ["//go/analysis:__subpackages__"],
+    deps = [
+        "//go/analysis",
+        "//internal/analysisinternal",
+        "//internal/diff",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":analysisflags",
+    visibility = ["//go/analysis:__subpackages__"],
+)
+
+go_test(
+    name = "analysisflags_test",
+    srcs = [
+        "flags_test.go",
+        "url_test.go",
+    ],
+    deps = [
+        ":analysisflags",
+        "//go/analysis",
+    ],
+)
diff -urN b/go/analysis/internal/BUILD.bazel c/go/analysis/internal/BUILD.bazel
--- b/go/analysis/internal/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/internal/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "internal",
+    srcs = ["internal.go"],
+    importpath = "golang.org/x/tools/go/analysis/internal",
+    visibility = ["//go/analysis:__subpackages__"],
+    deps = ["//go/analysis"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":internal",
+    visibility = ["//go/analysis:__subpackages__"],
+)
diff -urN b/go/analysis/internal/checker/BUILD.bazel c/go/analysis/internal/checker/BUILD.bazel
--- b/go/analysis/internal/checker/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/internal/checker/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,47 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "checker",
+    srcs = ["checker.go"],
+    importpath = "golang.org/x/tools/go/analysis/internal/checker",
+    visibility = ["//go/analysis:__subpackages__"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/checker",
+        "//go/analysis/internal",
+        "//go/analysis/internal/analysisflags",
+        "//go/packages",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":checker",
+    visibility = ["//go/analysis:__subpackages__"],
+)
+
+go_test(
+    name = "checker_test",
+    srcs = [
+        "checker_test.go",
+        "fix_test.go",
+        "start_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    deps = [
+        ":checker",
+        "//go/analysis",
+        "//go/analysis/analysistest",
+        "//go/analysis/checker",
+        "//go/analysis/internal/analysisflags",
+        "//go/analysis/multichecker",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//go/packages",
+        "//internal/diff",
+        "//internal/expect",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/go/analysis/internal/versiontest/BUILD.bazel c/go/analysis/internal/versiontest/BUILD.bazel
--- b/go/analysis/internal/versiontest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/internal/versiontest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,13 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_test")
+
+go_test(
+    name = "versiontest_test",
+    srcs = ["version_test.go"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/analysistest",
+        "//go/analysis/multichecker",
+        "//go/analysis/singlechecker",
+        "//internal/testenv",
+    ],
+)
diff -urN b/go/analysis/multichecker/BUILD.bazel c/go/analysis/multichecker/BUILD.bazel
--- b/go/analysis/multichecker/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/multichecker/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,31 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "multichecker",
+    srcs = ["multichecker.go"],
+    importpath = "golang.org/x/tools/go/analysis/multichecker",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/internal/analysisflags",
+        "//go/analysis/internal/checker",
+        "//go/analysis/unitchecker",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":multichecker",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "multichecker_test",
+    srcs = ["multichecker_test.go"],
+    deps = [
+        ":multichecker",
+        "//go/analysis",
+        "//go/analysis/passes/findcall",
+        "//internal/testenv",
+    ],
+)
diff -urN b/go/analysis/passes/appends/BUILD.bazel c/go/analysis/passes/appends/BUILD.bazel
--- b/go/analysis/passes/appends/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/appends/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "appends",
+    srcs = [
+        "appends.go",
+        "doc.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/appends",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":appends",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "appends_test",
+    srcs = ["appends_test.go"],
+    deps = [
+        ":appends",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/appends/testdata/src/a/BUILD.bazel c/go/analysis/passes/appends/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/appends/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/appends/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/appends/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/appends/testdata/src/b/BUILD.bazel c/go/analysis/passes/appends/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/appends/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/appends/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/appends/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/asmdecl/BUILD.bazel c/go/analysis/passes/asmdecl/BUILD.bazel
--- b/go/analysis/passes/asmdecl/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/asmdecl/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "asmdecl",
+    srcs = ["asmdecl.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/asmdecl",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/internal/analysisutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":asmdecl",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "asmdecl_test",
+    srcs = ["asmdecl_test.go"],
+    deps = [
+        ":asmdecl",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/asmdecl/testdata/src/a/BUILD.bazel c/go/analysis/passes/asmdecl/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/asmdecl/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/asmdecl/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,26 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "asm.go",
+        "asm1.s",
+        "asm11.s",
+        "asm2.s",
+        "asm3.s",
+        "asm4.s",
+        "asm5.s",
+        "asm6.s",
+        "asm7.s",
+        "asm8.s",
+        "asm9.s",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/asmdecl/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/assign/BUILD.bazel c/go/analysis/passes/assign/BUILD.bazel
--- b/go/analysis/passes/assign/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/assign/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "assign",
+    srcs = [
+        "assign.go",
+        "doc.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/assign",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/astutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":assign",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "assign_test",
+    srcs = ["assign_test.go"],
+    deps = [
+        ":assign",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/assign/testdata/src/a/BUILD.bazel c/go/analysis/passes/assign/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/assign/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/assign/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/assign/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/assign/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/assign/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/assign/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/assign/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/assign/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/atomic/BUILD.bazel c/go/analysis/passes/atomic/BUILD.bazel
--- b/go/analysis/passes/atomic/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/atomic/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "atomic",
+    srcs = [
+        "atomic.go",
+        "doc.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/atomic",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/astutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":atomic",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "atomic_test",
+    srcs = ["atomic_test.go"],
+    deps = [
+        ":atomic",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/atomic/testdata/src/a/BUILD.bazel c/go/analysis/passes/atomic/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/atomic/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/atomic/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/atomic/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/atomic/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/atomic/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/atomic/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/atomic/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/atomic/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/atomicalign/BUILD.bazel c/go/analysis/passes/atomicalign/BUILD.bazel
--- b/go/analysis/passes/atomicalign/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/atomicalign/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "atomicalign",
+    srcs = ["atomicalign.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/atomicalign",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":atomicalign",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "atomicalign_test",
+    srcs = ["atomicalign_test.go"],
+    deps = [
+        ":atomicalign",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/atomicalign/testdata/src/a/BUILD.bazel c/go/analysis/passes/atomicalign/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/atomicalign/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/atomicalign/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "a.go",
+        "stub.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/atomicalign/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/atomicalign/testdata/src/b/BUILD.bazel c/go/analysis/passes/atomicalign/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/atomicalign/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/atomicalign/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = [
+        "b.go",
+        "stub.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/atomicalign/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/bools/BUILD.bazel c/go/analysis/passes/bools/BUILD.bazel
--- b/go/analysis/passes/bools/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/bools/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "bools",
+    srcs = ["bools.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/bools",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/astutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":bools",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "bools_test",
+    srcs = ["bools_test.go"],
+    deps = [
+        ":bools",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/bools/testdata/src/a/BUILD.bazel c/go/analysis/passes/bools/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/bools/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/bools/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/bools/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/bools/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/bools/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/bools/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/bools/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/bools/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/buildssa/BUILD.bazel c/go/analysis/passes/buildssa/BUILD.bazel
--- b/go/analysis/passes/buildssa/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/buildssa/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "buildssa",
+    srcs = ["buildssa.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/buildssa",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/ssa",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":buildssa",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "buildssa_test",
+    srcs = ["buildssa_test.go"],
+    deps = [
+        ":buildssa",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/buildssa/testdata/src/a/BUILD.bazel c/go/analysis/passes/buildssa/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/buildssa/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/buildssa/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/buildssa/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/buildssa/testdata/src/b/BUILD.bazel c/go/analysis/passes/buildssa/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/buildssa/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/buildssa/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/buildssa/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/buildssa/testdata/src/c/BUILD.bazel c/go/analysis/passes/buildssa/testdata/src/c/BUILD.bazel
--- b/go/analysis/passes/buildssa/testdata/src/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/buildssa/testdata/src/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/buildssa/testdata/src/c",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/buildtag/BUILD.bazel c/go/analysis/passes/buildtag/BUILD.bazel
--- b/go/analysis/passes/buildtag/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/buildtag/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "buildtag",
+    srcs = ["buildtag.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/buildtag",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/internal/analysisutil",
+        "//internal/analysisinternal",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":buildtag",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "buildtag_test",
+    srcs = ["buildtag_test.go"],
+    deps = [
+        ":buildtag",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/buildtag/testdata/src/a/BUILD.bazel c/go/analysis/passes/buildtag/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/buildtag/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/buildtag/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "buildtag4.go",
+        "buildtag5.go",
+        "buildtag6.s",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/buildtag/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/buildtag/testdata/src/b/BUILD.bazel c/go/analysis/passes/buildtag/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/buildtag/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/buildtag/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["vers1.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/buildtag/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/cgocall/BUILD.bazel c/go/analysis/passes/cgocall/BUILD.bazel
--- b/go/analysis/passes/cgocall/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/cgocall/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,31 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "cgocall",
+    srcs = [
+        "cgocall.go",
+        "cgocall_go120.go",
+        "cgocall_go121.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/cgocall",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":cgocall",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "cgocall_test",
+    srcs = ["cgocall_test.go"],
+    deps = [
+        ":cgocall",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/cgocall/testdata/src/a/BUILD.bazel c/go/analysis/passes/cgocall/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/cgocall/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/cgocall/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "cgo.go",
+        "cgo3.go",
+    ],
+    cgo = True,
+    importpath = "golang.org/x/tools/go/analysis/passes/cgocall/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/cgocall/testdata/src/b/BUILD.bazel c/go/analysis/passes/cgocall/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/cgocall/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/cgocall/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/cgocall/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/cgocall/testdata/src/c/BUILD.bazel c/go/analysis/passes/cgocall/testdata/src/c/BUILD.bazel
--- b/go/analysis/passes/cgocall/testdata/src/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/cgocall/testdata/src/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/cgocall/testdata/src/c",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/cgocall/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/cgocall/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/cgocall/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/cgocall/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    cgo = True,
+    importpath = "golang.org/x/tools/go/analysis/passes/cgocall/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/composite/BUILD.bazel c/go/analysis/passes/composite/BUILD.bazel
--- b/go/analysis/passes/composite/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/composite/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,32 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "composite",
+    srcs = [
+        "composite.go",
+        "whitelist.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/composite",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":composite",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "composite_test",
+    srcs = ["composite_test.go"],
+    deps = [
+        ":composite",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/composite/testdata/src/a/BUILD.bazel c/go/analysis/passes/composite/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/composite/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/composite/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/composite/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "a_test",
+    srcs = ["a_fuzz_test.go"],
+    embed = [":a"],
+)
diff -urN b/go/analysis/passes/composite/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/composite/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/composite/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/composite/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/composite/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/composite/testdata/src/typeparams/lib/BUILD.bazel c/go/analysis/passes/composite/testdata/src/typeparams/lib/BUILD.bazel
--- b/go/analysis/passes/composite/testdata/src/typeparams/lib/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/composite/testdata/src/typeparams/lib/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "lib",
+    srcs = ["lib.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/composite/testdata/src/typeparams/lib",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":lib",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/copylock/BUILD.bazel c/go/analysis/passes/copylock/BUILD.bazel
--- b/go/analysis/passes/copylock/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/copylock/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,33 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "copylock",
+    srcs = ["copylock.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/copylock",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//internal/astutil",
+        "//internal/typeparams",
+        "//internal/typesinternal",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":copylock",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "copylock_test",
+    srcs = ["copylock_test.go"],
+    deps = [
+        ":copylock",
+        "//go/analysis/analysistest",
+        "//internal/testfiles",
+    ],
+)
diff -urN b/go/analysis/passes/copylock/testdata/src/a/BUILD.bazel c/go/analysis/passes/copylock/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/copylock/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/copylock/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "copylock.go",
+        "copylock_func.go",
+        "copylock_range.go",
+        "issue61678.go",
+        "newexpr_go126.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/copylock/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/copylock/testdata/src/issue67787/BUILD.bazel c/go/analysis/passes/copylock/testdata/src/issue67787/BUILD.bazel
--- b/go/analysis/passes/copylock/testdata/src/issue67787/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/copylock/testdata/src/issue67787/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "issue67787",
+    srcs = ["issue67787.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/copylock/testdata/src/issue67787",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":issue67787",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/copylock/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/copylock/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/copylock/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/copylock/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/copylock/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/copylock/testdata/src/unfortunate/BUILD.bazel c/go/analysis/passes/copylock/testdata/src/unfortunate/BUILD.bazel
--- b/go/analysis/passes/copylock/testdata/src/unfortunate/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/copylock/testdata/src/unfortunate/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "unfortunate",
+    srcs = [
+        "local_go123.go",
+        "local_go124.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/copylock/testdata/src/unfortunate",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unfortunate",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/ctrlflow/BUILD.bazel c/go/analysis/passes/ctrlflow/BUILD.bazel
--- b/go/analysis/passes/ctrlflow/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ctrlflow/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "ctrlflow",
+    srcs = ["ctrlflow.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ctrlflow",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//go/cfg",
+        "//go/types/typeutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":ctrlflow",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "ctrlflow_test",
+    srcs = ["ctrlflow_test.go"],
+    deps = [
+        ":ctrlflow",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/ctrlflow/testdata/src/a/BUILD.bazel c/go/analysis/passes/ctrlflow/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/ctrlflow/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ctrlflow/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ctrlflow/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/ctrlflow/testdata/src/lib/BUILD.bazel c/go/analysis/passes/ctrlflow/testdata/src/lib/BUILD.bazel
--- b/go/analysis/passes/ctrlflow/testdata/src/lib/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ctrlflow/testdata/src/lib/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "lib",
+    srcs = ["lib.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ctrlflow/testdata/src/lib",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":lib",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/ctrlflow/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/ctrlflow/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/ctrlflow/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ctrlflow/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ctrlflow/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/deepequalerrors/BUILD.bazel c/go/analysis/passes/deepequalerrors/BUILD.bazel
--- b/go/analysis/passes/deepequalerrors/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/deepequalerrors/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "deepequalerrors",
+    srcs = ["deepequalerrors.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/deepequalerrors",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":deepequalerrors",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "deepequalerrors_test",
+    srcs = ["deepequalerrors_test.go"],
+    deps = [
+        ":deepequalerrors",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/deepequalerrors/testdata/src/a/BUILD.bazel c/go/analysis/passes/deepequalerrors/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/deepequalerrors/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/deepequalerrors/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/deepequalerrors/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/deepequalerrors/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/deepequalerrors/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/deepequalerrors/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/deepequalerrors/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/deepequalerrors/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/defers/BUILD.bazel c/go/analysis/passes/defers/BUILD.bazel
--- b/go/analysis/passes/defers/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/defers/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,35 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "defers",
+    srcs = [
+        "defers.go",
+        "doc.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/defers",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":defers",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "defers_test",
+    srcs = ["defers_test.go"],
+    deps = [
+        ":defers",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/defers/cmd/defers/BUILD.bazel c/go/analysis/passes/defers/cmd/defers/BUILD.bazel
--- b/go/analysis/passes/defers/cmd/defers/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/defers/cmd/defers/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "defers_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/defers/cmd/defers",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/defers",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "defers",
+    embed = [":defers_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/defers/testdata/src/a/BUILD.bazel c/go/analysis/passes/defers/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/defers/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/defers/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/defers/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/directive/BUILD.bazel c/go/analysis/passes/directive/BUILD.bazel
--- b/go/analysis/passes/directive/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/directive/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "directive",
+    srcs = ["directive.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/directive",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/internal/analysisutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":directive",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "directive_test",
+    srcs = ["directive_test.go"],
+    deps = [
+        ":directive",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/directive/testdata/src/a/BUILD.bazel c/go/analysis/passes/directive/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/directive/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/directive/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "a",
+    srcs = [
+        "misplaced.s",
+        "p.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/directive/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "a_test",
+    srcs = ["misplaced_test.go"],
+)
diff -urN b/go/analysis/passes/errorsas/BUILD.bazel c/go/analysis/passes/errorsas/BUILD.bazel
--- b/go/analysis/passes/errorsas/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/errorsas/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,28 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "errorsas",
+    srcs = ["errorsas.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/errorsas",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//internal/analysisinternal/typeindex",
+        "//internal/typesinternal/typeindex",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":errorsas",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "errorsas_test",
+    srcs = ["errorsas_test.go"],
+    deps = [
+        ":errorsas",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/errorsas/testdata/src/a/BUILD.bazel c/go/analysis/passes/errorsas/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/errorsas/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/errorsas/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/errorsas/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/errorsas/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/errorsas/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/errorsas/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/errorsas/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/errorsas/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/fieldalignment/BUILD.bazel c/go/analysis/passes/fieldalignment/BUILD.bazel
--- b/go/analysis/passes/fieldalignment/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/fieldalignment/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,28 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "fieldalignment",
+    srcs = ["fieldalignment.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/fieldalignment",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fieldalignment",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "fieldalignment_test",
+    srcs = ["fieldalignment_test.go"],
+    deps = [
+        ":fieldalignment",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/fieldalignment/cmd/fieldalignment/BUILD.bazel c/go/analysis/passes/fieldalignment/cmd/fieldalignment/BUILD.bazel
--- b/go/analysis/passes/fieldalignment/cmd/fieldalignment/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/fieldalignment/cmd/fieldalignment/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "fieldalignment_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/fieldalignment/cmd/fieldalignment",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/fieldalignment",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "fieldalignment",
+    embed = [":fieldalignment_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/fieldalignment/testdata/src/a/BUILD.bazel c/go/analysis/passes/fieldalignment/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/fieldalignment/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/fieldalignment/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "a.go",
+        "a_386.go",
+        "a_amd64.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/fieldalignment/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/findcall/BUILD.bazel c/go/analysis/passes/findcall/BUILD.bazel
--- b/go/analysis/passes/findcall/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/findcall/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "findcall",
+    srcs = ["findcall.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/findcall",
+    visibility = ["//visibility:public"],
+    deps = ["//go/analysis"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":findcall",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "findcall_test",
+    srcs = ["findcall_test.go"],
+    deps = [
+        ":findcall",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/findcall/cmd/findcall/BUILD.bazel c/go/analysis/passes/findcall/cmd/findcall/BUILD.bazel
--- b/go/analysis/passes/findcall/cmd/findcall/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/findcall/cmd/findcall/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "findcall_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/findcall/cmd/findcall",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/findcall",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "findcall",
+    embed = [":findcall_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/findcall/testdata/src/a/BUILD.bazel c/go/analysis/passes/findcall/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/findcall/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/findcall/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "a_lib",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/findcall/testdata/src/a",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "a",
+    embed = [":a_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/framepointer/BUILD.bazel c/go/analysis/passes/framepointer/BUILD.bazel
--- b/go/analysis/passes/framepointer/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/framepointer/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "framepointer",
+    srcs = ["framepointer.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/framepointer",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/internal/analysisutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":framepointer",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "framepointer_test",
+    srcs = ["framepointer_test.go"],
+    deps = [
+        ":framepointer",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/framepointer/testdata/src/a/BUILD.bazel c/go/analysis/passes/framepointer/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/framepointer/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/framepointer/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,21 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "asm.go",
+        "asm_amd64.s",
+        "asm_arm64.s",
+        "asm_darwin_amd64.s",
+        "asm_linux_amd64.s",
+        "asm_windows_amd64.s",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/framepointer/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/gofix/BUILD.bazel c/go/analysis/passes/gofix/BUILD.bazel
--- b/go/analysis/passes/gofix/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/gofix/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "gofix",
+    srcs = [
+        "doc.go",
+        "gofix.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/gofix",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/gofixdirective",
+        "//go/ast/inspector",
+        "//internal/analysisinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gofix",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "gofix_test",
+    srcs = ["gofix_test.go"],
+    deps = [
+        ":gofix",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/gofix/testdata/src/a/BUILD.bazel c/go/analysis/passes/gofix/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/gofix/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/gofix/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/gofix/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/hostport/BUILD.bazel c/go/analysis/passes/hostport/BUILD.bazel
--- b/go/analysis/passes/hostport/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/hostport/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "hostport",
+    srcs = ["hostport.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/hostport",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/types/typeutil",
+        "//internal/analysisinternal/typeindex",
+        "//internal/typesinternal/typeindex",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":hostport",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "hostport_test",
+    srcs = ["hostport_test.go"],
+    deps = [
+        ":hostport",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/hostport/testdata/src/a/BUILD.bazel c/go/analysis/passes/hostport/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/hostport/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/hostport/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/hostport/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/httpmux/BUILD.bazel c/go/analysis/passes/httpmux/BUILD.bazel
--- b/go/analysis/passes/httpmux/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/httpmux/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "httpmux",
+    srcs = ["httpmux.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/httpmux",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+        "@org_golang_x_mod//semver:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":httpmux",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "httpmux_test",
+    srcs = ["httpmux_test.go"],
+    embed = [":httpmux"],
+    deps = ["//go/analysis/analysistest"],
+)
diff -urN b/go/analysis/passes/httpmux/cmd/httpmux/BUILD.bazel c/go/analysis/passes/httpmux/cmd/httpmux/BUILD.bazel
--- b/go/analysis/passes/httpmux/cmd/httpmux/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/httpmux/cmd/httpmux/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "httpmux_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/httpmux/cmd/httpmux",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/httpmux",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "httpmux",
+    embed = [":httpmux_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/httpmux/testdata/src/a/BUILD.bazel c/go/analysis/passes/httpmux/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/httpmux/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/httpmux/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/httpmux/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/httpresponse/BUILD.bazel c/go/analysis/passes/httpresponse/BUILD.bazel
--- b/go/analysis/passes/httpresponse/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/httpresponse/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "httpresponse",
+    srcs = ["httpresponse.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/httpresponse",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":httpresponse",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "httpresponse_test",
+    srcs = ["httpresponse_test.go"],
+    deps = [
+        ":httpresponse",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/httpresponse/testdata/src/a/BUILD.bazel c/go/analysis/passes/httpresponse/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/httpresponse/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/httpresponse/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/httpresponse/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/httpresponse/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/httpresponse/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/httpresponse/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/httpresponse/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/httpresponse/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/ifaceassert/BUILD.bazel c/go/analysis/passes/ifaceassert/BUILD.bazel
--- b/go/analysis/passes/ifaceassert/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ifaceassert/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "ifaceassert",
+    srcs = [
+        "doc.go",
+        "ifaceassert.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ifaceassert",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":ifaceassert",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "ifaceassert_test",
+    srcs = ["ifaceassert_test.go"],
+    deps = [
+        ":ifaceassert",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/ifaceassert/cmd/ifaceassert/BUILD.bazel c/go/analysis/passes/ifaceassert/cmd/ifaceassert/BUILD.bazel
--- b/go/analysis/passes/ifaceassert/cmd/ifaceassert/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ifaceassert/cmd/ifaceassert/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "ifaceassert_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ifaceassert/cmd/ifaceassert",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/ifaceassert",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "ifaceassert",
+    embed = [":ifaceassert_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/ifaceassert/testdata/src/a/BUILD.bazel c/go/analysis/passes/ifaceassert/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/ifaceassert/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ifaceassert/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ifaceassert/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/ifaceassert/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/ifaceassert/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/ifaceassert/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/ifaceassert/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/ifaceassert/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inline/BUILD.bazel c/go/analysis/passes/inline/BUILD.bazel
--- b/go/analysis/passes/inline/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,43 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "inline",
+    srcs = [
+        "doc.go",
+        "gofix.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/gofixdirective",
+        "//go/ast/edge",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/analysisinternal",
+        "//internal/astutil",
+        "//internal/diff",
+        "//internal/refactor",
+        "//internal/refactor/inline",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":inline",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "inline_test",
+    srcs = ["gofix_test.go"],
+    embed = [":inline"],
+    deps = [
+        "//go/analysis/analysistest",
+        "//internal/testenv",
+        "@com_github_google_go_cmp//cmp:go_default_library",
+    ],
+)
diff -urN b/go/analysis/passes/inline/cmd/inline/BUILD.bazel c/go/analysis/passes/inline/cmd/inline/BUILD.bazel
--- b/go/analysis/passes/inline/cmd/inline/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/cmd/inline/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "inline_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/cmd/inline",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/inline",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "inline",
+    embed = [":inline_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inline/testdata/src/a/BUILD.bazel c/go/analysis/passes/inline/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/inline/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inline/testdata/src/a/internal/BUILD.bazel c/go/analysis/passes/inline/testdata/src/a/internal/BUILD.bazel
--- b/go/analysis/passes/inline/testdata/src/a/internal/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/testdata/src/a/internal/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "internal",
+    srcs = ["d.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/testdata/src/a/internal",
+    visibility = ["//go/analysis/passes/inline/testdata/src/a:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":internal",
+    visibility = ["//go/analysis/passes/inline/testdata/src/a:__subpackages__"],
+)
diff -urN b/go/analysis/passes/inline/testdata/src/b/BUILD.bazel c/go/analysis/passes/inline/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/inline/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inline/testdata/src/binding_false/BUILD.bazel c/go/analysis/passes/inline/testdata/src/binding_false/BUILD.bazel
--- b/go/analysis/passes/inline/testdata/src/binding_false/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/testdata/src/binding_false/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "binding_false",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/testdata/src/binding_false",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":binding_false",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inline/testdata/src/binding_true/BUILD.bazel c/go/analysis/passes/inline/testdata/src/binding_true/BUILD.bazel
--- b/go/analysis/passes/inline/testdata/src/binding_true/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/testdata/src/binding_true/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "binding_true",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/testdata/src/binding_true",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":binding_true",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inline/testdata/src/c/BUILD.bazel c/go/analysis/passes/inline/testdata/src/c/BUILD.bazel
--- b/go/analysis/passes/inline/testdata/src/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/testdata/src/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/testdata/src/c",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inline/testdata/src/directive/BUILD.bazel c/go/analysis/passes/inline/testdata/src/directive/BUILD.bazel
--- b/go/analysis/passes/inline/testdata/src/directive/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inline/testdata/src/directive/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "directive",
+    srcs = ["directive.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inline/testdata/src/directive",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":directive",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/inspect/BUILD.bazel c/go/analysis/passes/inspect/BUILD.bazel
--- b/go/analysis/passes/inspect/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/inspect/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "inspect",
+    srcs = ["inspect.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/inspect",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/ast/inspector",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":inspect",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/internal/analysisutil/BUILD.bazel c/go/analysis/passes/internal/analysisutil/BUILD.bazel
--- b/go/analysis/passes/internal/analysisutil/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/internal/analysisutil/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "analysisutil",
+    srcs = ["util.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/internal/analysisutil",
+    visibility = ["//go/analysis/passes:__subpackages__"],
+    deps = [
+        "//go/analysis",
+        "//internal/analysisinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":analysisutil",
+    visibility = ["//go/analysis/passes:__subpackages__"],
+)
+
+go_test(
+    name = "analysisutil_test",
+    srcs = ["util_test.go"],
+    deps = [":analysisutil"],
+)
diff -urN b/go/analysis/passes/internal/gofixdirective/BUILD.bazel c/go/analysis/passes/internal/gofixdirective/BUILD.bazel
--- b/go/analysis/passes/internal/gofixdirective/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/internal/gofixdirective/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,19 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "gofixdirective",
+    srcs = ["gofixdirective.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/internal/gofixdirective",
+    visibility = ["//go/analysis/passes:__subpackages__"],
+    deps = [
+        "//go/analysis",
+        "//go/ast/inspector",
+        "//internal/astutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gofixdirective",
+    visibility = ["//go/analysis/passes:__subpackages__"],
+)
diff -urN b/go/analysis/passes/loopclosure/BUILD.bazel c/go/analysis/passes/loopclosure/BUILD.bazel
--- b/go/analysis/passes/loopclosure/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/loopclosure/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,37 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "loopclosure",
+    srcs = [
+        "doc.go",
+        "loopclosure.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/loopclosure",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":loopclosure",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "loopclosure_test",
+    srcs = ["loopclosure_test.go"],
+    deps = [
+        ":loopclosure",
+        "//go/analysis/analysistest",
+        "//internal/testfiles",
+    ],
+)
diff -urN b/go/analysis/passes/loopclosure/testdata/src/a/BUILD.bazel c/go/analysis/passes/loopclosure/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/loopclosure/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/loopclosure/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "a.go",
+        "b.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/loopclosure/testdata/src/a",
+    visibility = ["//visibility:public"],
+    deps = ["@org_golang_x_sync//errgroup:go_default_library"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/loopclosure/testdata/src/golang.org/x/sync/errgroup/BUILD.bazel c/go/analysis/passes/loopclosure/testdata/src/golang.org/x/sync/errgroup/BUILD.bazel
--- b/go/analysis/passes/loopclosure/testdata/src/golang.org/x/sync/errgroup/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/loopclosure/testdata/src/golang.org/x/sync/errgroup/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "errgroup",
+    srcs = ["errgroup.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/loopclosure/testdata/src/golang.org/x/sync/errgroup",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":errgroup",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/loopclosure/testdata/src/subtests/BUILD.bazel c/go/analysis/passes/loopclosure/testdata/src/subtests/BUILD.bazel
--- b/go/analysis/passes/loopclosure/testdata/src/subtests/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/loopclosure/testdata/src/subtests/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "subtests",
+    srcs = ["subtest.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/loopclosure/testdata/src/subtests",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":subtests",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/loopclosure/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/loopclosure/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/loopclosure/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/loopclosure/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/loopclosure/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+    deps = ["@org_golang_x_sync//errgroup:go_default_library"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/lostcancel/BUILD.bazel c/go/analysis/passes/lostcancel/BUILD.bazel
--- b/go/analysis/passes/lostcancel/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/lostcancel/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,37 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "lostcancel",
+    srcs = [
+        "doc.go",
+        "lostcancel.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/lostcancel",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/ctrlflow",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/cfg",
+        "//internal/astutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":lostcancel",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "lostcancel_test",
+    srcs = ["lostcancel_test.go"],
+    deps = [
+        ":lostcancel",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/lostcancel/cmd/lostcancel/BUILD.bazel c/go/analysis/passes/lostcancel/cmd/lostcancel/BUILD.bazel
--- b/go/analysis/passes/lostcancel/cmd/lostcancel/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/lostcancel/cmd/lostcancel/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "lostcancel_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/lostcancel/cmd/lostcancel",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/lostcancel",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "lostcancel",
+    embed = [":lostcancel_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/lostcancel/testdata/src/a/BUILD.bazel c/go/analysis/passes/lostcancel/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/lostcancel/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/lostcancel/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/lostcancel/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/lostcancel/testdata/src/b/BUILD.bazel c/go/analysis/passes/lostcancel/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/lostcancel/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/lostcancel/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "b_lib",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/lostcancel/testdata/src/b",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "b",
+    embed = [":b_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/lostcancel/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/lostcancel/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/lostcancel/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/lostcancel/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/lostcancel/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/BUILD.bazel c/go/analysis/passes/modernize/BUILD.bazel
--- b/go/analysis/passes/modernize/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,68 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "modernize",
+    srcs = [
+        "any.go",
+        "bloop.go",
+        "doc.go",
+        "errorsastype.go",
+        "fmtappendf.go",
+        "forvar.go",
+        "maps.go",
+        "minmax.go",
+        "modernize.go",
+        "newexpr.go",
+        "omitzero.go",
+        "rangeint.go",
+        "reflect.go",
+        "slices.go",
+        "slicescontains.go",
+        "slicesdelete.go",
+        "sortslice.go",
+        "stditerators.go",
+        "stringsbuilder.go",
+        "stringscutprefix.go",
+        "stringsseq.go",
+        "testingcontext.go",
+        "waitgroup.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/edge",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/analysisinternal",
+        "//internal/analysisinternal/generated",
+        "//internal/analysisinternal/typeindex",
+        "//internal/astutil",
+        "//internal/goplsexport",
+        "//internal/moreiters",
+        "//internal/refactor",
+        "//internal/stdlib",
+        "//internal/typeparams",
+        "//internal/typesinternal",
+        "//internal/typesinternal/typeindex",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":modernize",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "modernize_test",
+    srcs = ["modernize_test.go"],
+    deps = [
+        ":modernize",
+        "//go/analysis/analysistest",
+        "//internal/goplsexport",
+    ],
+)
diff -urN b/go/analysis/passes/modernize/cmd/modernize/BUILD.bazel c/go/analysis/passes/modernize/cmd/modernize/BUILD.bazel
--- b/go/analysis/passes/modernize/cmd/modernize/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/cmd/modernize/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "modernize_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/cmd/modernize",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/multichecker",
+        "//go/analysis/passes/modernize",
+    ],
+)
+
+go_binary(
+    name = "modernize",
+    embed = [":modernize_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/any/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/any/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/any/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/any/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "any",
+    srcs = ["any.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/any",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":any",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/appendclipped/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/appendclipped/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/appendclipped/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/appendclipped/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "appendclipped",
+    srcs = [
+        "appendclipped.go",
+        "bytesclone.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/appendclipped",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":appendclipped",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/bloop/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/bloop/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/bloop/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/bloop/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "bloop",
+    srcs = ["bloop.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/bloop",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":bloop",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "bloop_test",
+    srcs = ["bloop_test.go"],
+    embed = [":bloop"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/errorsastype/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/errorsastype/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/errorsastype/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/errorsastype/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "errorsastype",
+    srcs = ["errorsastype.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/errorsastype",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":errorsastype",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/errorsastype/dotimport/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/errorsastype/dotimport/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/errorsastype/dotimport/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/errorsastype/dotimport/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "dotimport",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/errorsastype/dotimport",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":dotimport",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/fieldsseq/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/fieldsseq/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/fieldsseq/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/fieldsseq/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "fieldsseq",
+    srcs = [
+        "fieldsseq.go",
+        "fieldsseq_go123.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/fieldsseq",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fieldsseq",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/fmtappendf/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/fmtappendf/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/fmtappendf/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/fmtappendf/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "fmtappendf",
+    srcs = ["fmtappendf.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/fmtappendf",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fmtappendf",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/forvar/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/forvar/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/forvar/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/forvar/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "forvar",
+    srcs = ["forvar.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/forvar",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":forvar",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/mapsloop/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/mapsloop/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/mapsloop/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/mapsloop/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "mapsloop",
+    srcs = [
+        "mapsloop.go",
+        "mapsloop_dot.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/mapsloop",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":mapsloop",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/minmax/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/minmax/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/minmax/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/minmax/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "minmax",
+    srcs = ["minmax.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/minmax",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":minmax",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/minmax/nonstrict/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/minmax/nonstrict/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/minmax/nonstrict/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/minmax/nonstrict/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "nonstrict",
+    srcs = ["nonstrict.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/minmax/nonstrict",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":nonstrict",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/minmax/userdefined/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/minmax/userdefined/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/minmax/userdefined/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/minmax/userdefined/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "userdefined",
+    srcs = ["userdefined.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/minmax/userdefined",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":userdefined",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/minmax/wrongoperators/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/minmax/wrongoperators/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/minmax/wrongoperators/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/minmax/wrongoperators/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "wrongoperators",
+    srcs = ["wrongoperators.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/minmax/wrongoperators",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":wrongoperators",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/minmax/wrongreturn/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/minmax/wrongreturn/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/minmax/wrongreturn/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/minmax/wrongreturn/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "wrongreturn",
+    srcs = ["wrongreturn.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/minmax/wrongreturn",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":wrongreturn",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/newexpr/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/newexpr/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/newexpr/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/newexpr/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "newexpr",
+    srcs = [
+        "newexpr.go",
+        "newexpr_go125.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/newexpr",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":newexpr",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/omitzero/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/omitzero/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/omitzero/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/omitzero/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "omitzero",
+    srcs = ["omitzero.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/omitzero",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":omitzero",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/rangeint/a/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/rangeint/a/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/rangeint/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/rangeint/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/rangeint/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/rangeint/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/rangeint/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/rangeint/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/rangeint/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "rangeint",
+    srcs = ["rangeint.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/rangeint",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":rangeint",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/reflecttypefor/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/reflecttypefor/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/reflecttypefor/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/reflecttypefor/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "reflecttypefor",
+    srcs = ["reflecttypefor.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/reflecttypefor",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":reflecttypefor",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/slicescontains/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/slicescontains/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/slicescontains/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/slicescontains/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "slicescontains",
+    srcs = ["slicescontains.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/slicescontains",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":slicescontains",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/slicesdelete/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/slicesdelete/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/slicesdelete/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/slicesdelete/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "slicesdelete",
+    srcs = ["slicesdelete.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/slicesdelete",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":slicesdelete",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/slicessort/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/slicessort/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/slicessort/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/slicessort/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "slicessort",
+    srcs = [
+        "slicessort.go",
+        "slicessort_dot.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/slicessort",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":slicessort",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/splitseq/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/splitseq/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/splitseq/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/splitseq/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "splitseq",
+    srcs = [
+        "splitseq.go",
+        "splitseq_go123.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/splitseq",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":splitseq",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/stditerators/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/stditerators/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/stditerators/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/stditerators/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "stditerators",
+    srcs = ["stditerators.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/stditerators",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stditerators",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/stringsbuilder/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/stringsbuilder/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/stringsbuilder/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/stringsbuilder/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "stringsbuilder",
+    srcs = ["stringsbuilder.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/stringsbuilder",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stringsbuilder",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/stringscutprefix/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/stringscutprefix/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/stringscutprefix/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/stringscutprefix/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "stringscutprefix",
+    srcs = [
+        "stringscutprefix.go",
+        "stringscutprefix_dot.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/stringscutprefix",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stringscutprefix",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/stringscutprefix/bytescutprefix/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/stringscutprefix/bytescutprefix/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/stringscutprefix/bytescutprefix/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/stringscutprefix/bytescutprefix/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "bytescutprefix",
+    srcs = [
+        "bytescutprefix.go",
+        "bytescutprefix_dot.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/stringscutprefix/bytescutprefix",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":bytescutprefix",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/testingcontext/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/testingcontext/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/testingcontext/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/testingcontext/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "testingcontext",
+    srcs = ["testingcontext.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/testingcontext",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":testingcontext",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "testingcontext_test",
+    srcs = ["testingcontext_test.go"],
+    embed = [":testingcontext"],
+)
diff -urN b/go/analysis/passes/modernize/testdata/src/waitgroup/BUILD.bazel c/go/analysis/passes/modernize/testdata/src/waitgroup/BUILD.bazel
--- b/go/analysis/passes/modernize/testdata/src/waitgroup/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/modernize/testdata/src/waitgroup/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "waitgroup",
+    srcs = [
+        "waitgroup.go",
+        "waitgroup_alias.go",
+        "waitgroup_dot.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/modernize/testdata/src/waitgroup",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":waitgroup",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/nilfunc/BUILD.bazel c/go/analysis/passes/nilfunc/BUILD.bazel
--- b/go/analysis/passes/nilfunc/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilfunc/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "nilfunc",
+    srcs = [
+        "doc.go",
+        "nilfunc.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilfunc",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":nilfunc",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "nilfunc_test",
+    srcs = ["nilfunc_test.go"],
+    deps = [
+        ":nilfunc",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/nilfunc/testdata/src/a/BUILD.bazel c/go/analysis/passes/nilfunc/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/nilfunc/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilfunc/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilfunc/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/nilfunc/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/nilfunc/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/nilfunc/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilfunc/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilfunc/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/nilness/BUILD.bazel c/go/analysis/passes/nilness/BUILD.bazel
--- b/go/analysis/passes/nilness/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilness/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "nilness",
+    srcs = [
+        "doc.go",
+        "nilness.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilness",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/buildssa",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ssa",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":nilness",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "nilness_test",
+    srcs = ["nilness_test.go"],
+    deps = [
+        ":nilness",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/nilness/cmd/nilness/BUILD.bazel c/go/analysis/passes/nilness/cmd/nilness/BUILD.bazel
--- b/go/analysis/passes/nilness/cmd/nilness/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilness/cmd/nilness/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "nilness_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilness/cmd/nilness",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/nilness",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "nilness",
+    embed = [":nilness_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/nilness/testdata/src/a/BUILD.bazel c/go/analysis/passes/nilness/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/nilness/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilness/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilness/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/nilness/testdata/src/b/BUILD.bazel c/go/analysis/passes/nilness/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/nilness/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilness/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilness/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/nilness/testdata/src/c/BUILD.bazel c/go/analysis/passes/nilness/testdata/src/c/BUILD.bazel
--- b/go/analysis/passes/nilness/testdata/src/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilness/testdata/src/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilness/testdata/src/c",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/nilness/testdata/src/d/BUILD.bazel c/go/analysis/passes/nilness/testdata/src/d/BUILD.bazel
--- b/go/analysis/passes/nilness/testdata/src/d/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/nilness/testdata/src/d/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "d",
+    srcs = ["d.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/nilness/testdata/src/d",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":d",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/pkgfact/BUILD.bazel c/go/analysis/passes/pkgfact/BUILD.bazel
--- b/go/analysis/passes/pkgfact/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/pkgfact/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "pkgfact",
+    srcs = ["pkgfact.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/pkgfact",
+    visibility = ["//visibility:public"],
+    deps = ["//go/analysis"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":pkgfact",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "pkgfact_test",
+    srcs = ["pkgfact_test.go"],
+    deps = [
+        ":pkgfact",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/pkgfact/testdata/src/a/BUILD.bazel c/go/analysis/passes/pkgfact/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/pkgfact/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/pkgfact/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/pkgfact/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/pkgfact/testdata/src/b/BUILD.bazel c/go/analysis/passes/pkgfact/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/pkgfact/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/pkgfact/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/pkgfact/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/pkgfact/testdata/src/c/BUILD.bazel c/go/analysis/passes/pkgfact/testdata/src/c/BUILD.bazel
--- b/go/analysis/passes/pkgfact/testdata/src/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/pkgfact/testdata/src/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/pkgfact/testdata/src/c",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/printf/BUILD.bazel c/go/analysis/passes/printf/BUILD.bazel
--- b/go/analysis/passes/printf/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,44 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "printf",
+    srcs = [
+        "doc.go",
+        "printf.go",
+        "types.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/edge",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/analysisinternal",
+        "//internal/astutil",
+        "//internal/fmtstr",
+        "//internal/typeparams",
+        "//internal/typesinternal",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":printf",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "printf_test",
+    srcs = ["printf_test.go"],
+    deps = [
+        ":printf",
+        "//go/analysis/analysistest",
+        "//internal/testenv",
+        "//internal/testfiles",
+    ],
+)
diff -urN b/go/analysis/passes/printf/testdata/src/a/BUILD.bazel c/go/analysis/passes/printf/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/printf/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/printf/testdata/src/b/BUILD.bazel c/go/analysis/passes/printf/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/printf/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/printf/testdata/src/issue68744/BUILD.bazel c/go/analysis/passes/printf/testdata/src/issue68744/BUILD.bazel
--- b/go/analysis/passes/printf/testdata/src/issue68744/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/testdata/src/issue68744/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "issue68744",
+    srcs = ["issue68744.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf/testdata/src/issue68744",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":issue68744",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/printf/testdata/src/issue70572/BUILD.bazel c/go/analysis/passes/printf/testdata/src/issue70572/BUILD.bazel
--- b/go/analysis/passes/printf/testdata/src/issue70572/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/testdata/src/issue70572/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "issue70572",
+    srcs = ["issue70572.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf/testdata/src/issue70572",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":issue70572",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/printf/testdata/src/nofmt/BUILD.bazel c/go/analysis/passes/printf/testdata/src/nofmt/BUILD.bazel
--- b/go/analysis/passes/printf/testdata/src/nofmt/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/testdata/src/nofmt/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "nofmt",
+    srcs = ["nofmt.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf/testdata/src/nofmt",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":nofmt",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/printf/testdata/src/nonconst/BUILD.bazel c/go/analysis/passes/printf/testdata/src/nonconst/BUILD.bazel
--- b/go/analysis/passes/printf/testdata/src/nonconst/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/testdata/src/nonconst/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "nonconst",
+    srcs = ["nonconst.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf/testdata/src/nonconst",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":nonconst",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/printf/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/printf/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/printf/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/printf/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = [
+        "diagnostics.go",
+        "wrappers.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/printf/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/reflectvaluecompare/BUILD.bazel c/go/analysis/passes/reflectvaluecompare/BUILD.bazel
--- b/go/analysis/passes/reflectvaluecompare/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/reflectvaluecompare/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,35 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "reflectvaluecompare",
+    srcs = [
+        "doc.go",
+        "reflectvaluecompare.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/reflectvaluecompare",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":reflectvaluecompare",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "reflectvaluecompare_test",
+    srcs = ["reflectvaluecompare_test.go"],
+    deps = [
+        ":reflectvaluecompare",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/reflectvaluecompare/cmd/reflectvaluecompare/BUILD.bazel c/go/analysis/passes/reflectvaluecompare/cmd/reflectvaluecompare/BUILD.bazel
--- b/go/analysis/passes/reflectvaluecompare/cmd/reflectvaluecompare/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/reflectvaluecompare/cmd/reflectvaluecompare/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "reflectvaluecompare_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/reflectvaluecompare/cmd/reflectvaluecompare",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/reflectvaluecompare",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "reflectvaluecompare",
+    embed = [":reflectvaluecompare_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/reflectvaluecompare/testdata/src/a/BUILD.bazel c/go/analysis/passes/reflectvaluecompare/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/reflectvaluecompare/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/reflectvaluecompare/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/reflectvaluecompare/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/shadow/BUILD.bazel c/go/analysis/passes/shadow/BUILD.bazel
--- b/go/analysis/passes/shadow/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/shadow/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,33 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "shadow",
+    srcs = [
+        "doc.go",
+        "shadow.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/shadow",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":shadow",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "shadow_test",
+    srcs = ["shadow_test.go"],
+    deps = [
+        ":shadow",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/shadow/cmd/shadow/BUILD.bazel c/go/analysis/passes/shadow/cmd/shadow/BUILD.bazel
--- b/go/analysis/passes/shadow/cmd/shadow/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/shadow/cmd/shadow/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "shadow_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/shadow/cmd/shadow",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/shadow",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "shadow",
+    embed = [":shadow_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/shadow/testdata/src/a/BUILD.bazel c/go/analysis/passes/shadow/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/shadow/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/shadow/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/shadow/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/shift/BUILD.bazel c/go/analysis/passes/shift/BUILD.bazel
--- b/go/analysis/passes/shift/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/shift/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,33 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "shift",
+    srcs = [
+        "dead.go",
+        "shift.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/shift",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//internal/astutil",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":shift",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "shift_test",
+    srcs = ["shift_test.go"],
+    deps = [
+        ":shift",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/shift/testdata/src/a/BUILD.bazel c/go/analysis/passes/shift/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/shift/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/shift/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/shift/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/shift/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/shift/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/shift/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/shift/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/shift/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/sigchanyzer/BUILD.bazel c/go/analysis/passes/sigchanyzer/BUILD.bazel
--- b/go/analysis/passes/sigchanyzer/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/sigchanyzer/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "sigchanyzer",
+    srcs = [
+        "doc.go",
+        "sigchanyzer.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/sigchanyzer",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":sigchanyzer",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "sigchanyzer_test",
+    srcs = ["sigchanyzer_test.go"],
+    deps = [
+        ":sigchanyzer",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/sigchanyzer/testdata/src/a/BUILD.bazel c/go/analysis/passes/sigchanyzer/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/sigchanyzer/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/sigchanyzer/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/sigchanyzer/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/slog/BUILD.bazel c/go/analysis/passes/slog/BUILD.bazel
--- b/go/analysis/passes/slog/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/slog/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "slog",
+    srcs = [
+        "doc.go",
+        "slog.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/slog",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/astutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":slog",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "slog_test",
+    srcs = ["slog_test.go"],
+    embed = [":slog"],
+    deps = ["//go/analysis/analysistest"],
+)
diff -urN b/go/analysis/passes/slog/testdata/src/a/BUILD.bazel c/go/analysis/passes/slog/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/slog/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/slog/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/slog/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/slog/testdata/src/b/BUILD.bazel c/go/analysis/passes/slog/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/slog/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/slog/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/slog/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/sortslice/BUILD.bazel c/go/analysis/passes/sortslice/BUILD.bazel
--- b/go/analysis/passes/sortslice/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/sortslice/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "sortslice",
+    srcs = ["analyzer.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/sortslice",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":sortslice",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "sortslice_test",
+    srcs = ["analyzer_test.go"],
+    deps = [
+        ":sortslice",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/sortslice/testdata/src/a/BUILD.bazel c/go/analysis/passes/sortslice/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/sortslice/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/sortslice/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/sortslice/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/stdmethods/BUILD.bazel c/go/analysis/passes/stdmethods/BUILD.bazel
--- b/go/analysis/passes/stdmethods/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stdmethods/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,33 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "stdmethods",
+    srcs = [
+        "doc.go",
+        "stdmethods.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/stdmethods",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stdmethods",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "stdmethods_test",
+    srcs = ["stdmethods_test.go"],
+    deps = [
+        ":stdmethods",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/stdmethods/testdata/src/a/BUILD.bazel c/go/analysis/passes/stdmethods/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/stdmethods/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stdmethods/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "a.go",
+        "b.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/stdmethods/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/stdmethods/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/stdmethods/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/stdmethods/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stdmethods/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/stdmethods/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/stdversion/BUILD.bazel c/go/analysis/passes/stdversion/BUILD.bazel
--- b/go/analysis/passes/stdversion/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stdversion/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,33 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "stdversion",
+    srcs = ["stdversion.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/stdversion",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//internal/typesinternal",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stdversion",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "stdversion_test",
+    srcs = ["stdversion_test.go"],
+    data = glob(["testdata/**"]),
+    deps = [
+        ":stdversion",
+        "//go/analysis/analysistest",
+        "//internal/testenv",
+        "//internal/testfiles",
+    ],
+)
diff -urN b/go/analysis/passes/stringintconv/BUILD.bazel c/go/analysis/passes/stringintconv/BUILD.bazel
--- b/go/analysis/passes/stringintconv/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stringintconv/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "stringintconv",
+    srcs = [
+        "doc.go",
+        "string.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/stringintconv",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/refactor",
+        "//internal/typeparams",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stringintconv",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "stringintconv_test",
+    srcs = ["string_test.go"],
+    deps = [
+        ":stringintconv",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/stringintconv/cmd/stringintconv/BUILD.bazel c/go/analysis/passes/stringintconv/cmd/stringintconv/BUILD.bazel
--- b/go/analysis/passes/stringintconv/cmd/stringintconv/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stringintconv/cmd/stringintconv/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "stringintconv_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/stringintconv/cmd/stringintconv",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/stringintconv",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "stringintconv",
+    embed = [":stringintconv_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/stringintconv/testdata/src/a/BUILD.bazel c/go/analysis/passes/stringintconv/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/stringintconv/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stringintconv/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/stringintconv/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/stringintconv/testdata/src/fix/BUILD.bazel c/go/analysis/passes/stringintconv/testdata/src/fix/BUILD.bazel
--- b/go/analysis/passes/stringintconv/testdata/src/fix/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stringintconv/testdata/src/fix/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "fix",
+    srcs = [
+        "fix.go",
+        "fixdot.go",
+        "fixnamed.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/stringintconv/testdata/src/fix",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fix",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/stringintconv/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/stringintconv/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/stringintconv/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/stringintconv/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/stringintconv/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/structtag/BUILD.bazel c/go/analysis/passes/structtag/BUILD.bazel
--- b/go/analysis/passes/structtag/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/structtag/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,28 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "structtag",
+    srcs = ["structtag.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/structtag",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":structtag",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "structtag_test",
+    srcs = ["structtag_test.go"],
+    deps = [
+        ":structtag",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/structtag/testdata/src/a/b/BUILD.bazel c/go/analysis/passes/structtag/testdata/src/a/b/BUILD.bazel
--- b/go/analysis/passes/structtag/testdata/src/a/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/structtag/testdata/src/a/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/structtag/testdata/src/a/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/structtag/testdata/src/a/BUILD.bazel c/go/analysis/passes/structtag/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/structtag/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/structtag/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/structtag/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/testinggoroutine/BUILD.bazel c/go/analysis/passes/testinggoroutine/BUILD.bazel
--- b/go/analysis/passes/testinggoroutine/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/testinggoroutine/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "testinggoroutine",
+    srcs = [
+        "doc.go",
+        "testinggoroutine.go",
+        "util.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/testinggoroutine",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":testinggoroutine",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "testinggoroutine_test",
+    srcs = ["testinggoroutine_test.go"],
+    deps = [
+        ":testinggoroutine",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/testinggoroutine/testdata/src/a/BUILD.bazel c/go/analysis/passes/testinggoroutine/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/testinggoroutine/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/testinggoroutine/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "a.go",
+        "b.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/testinggoroutine/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/testinggoroutine/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/testinggoroutine/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/testinggoroutine/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/testinggoroutine/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/testinggoroutine/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/tests/BUILD.bazel c/go/analysis/passes/tests/BUILD.bazel
--- b/go/analysis/passes/tests/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/tests/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,33 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "tests",
+    srcs = [
+        "doc.go",
+        "tests.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/tests",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/internal/analysisutil",
+        "//internal/analysisinternal",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":tests",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "tests_test",
+    srcs = ["tests_test.go"],
+    deps = [
+        ":tests",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/tests/testdata/src/a/BUILD.bazel c/go/analysis/passes/tests/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/tests/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/tests/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/tests/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "a_test",
+    srcs = [
+        "a_test.go",
+        "ax_test.go",
+        "go118_test.go",
+    ],
+    embed = [":a"],
+)
diff -urN b/go/analysis/passes/tests/testdata/src/b/BUILD.bazel c/go/analysis/passes/tests/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/tests/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/tests/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/tests/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/tests/testdata/src/b_x_test/BUILD.bazel c/go/analysis/passes/tests/testdata/src/b_x_test/BUILD.bazel
--- b/go/analysis/passes/tests/testdata/src/b_x_test/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/tests/testdata/src/b_x_test/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,6 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_test")
+
+go_test(
+    name = "b_x_test_test",
+    srcs = ["b_test.go"],
+)
diff -urN b/go/analysis/passes/tests/testdata/src/divergent/BUILD.bazel c/go/analysis/passes/tests/testdata/src/divergent/BUILD.bazel
--- b/go/analysis/passes/tests/testdata/src/divergent/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/tests/testdata/src/divergent/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "divergent",
+    srcs = ["buf.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/tests/testdata/src/divergent",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":divergent",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "divergent_test",
+    srcs = ["buf_test.go"],
+    embed = [":divergent"],
+)
diff -urN b/go/analysis/passes/tests/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/tests/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/tests/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/tests/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/tests/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "typeparams_test",
+    srcs = ["typeparams_test.go"],
+    embed = [":typeparams"],
+)
diff -urN b/go/analysis/passes/timeformat/BUILD.bazel c/go/analysis/passes/timeformat/BUILD.bazel
--- b/go/analysis/passes/timeformat/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/timeformat/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,35 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "timeformat",
+    srcs = [
+        "doc.go",
+        "timeformat.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/timeformat",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":timeformat",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "timeformat_test",
+    srcs = ["timeformat_test.go"],
+    deps = [
+        ":timeformat",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/timeformat/testdata/src/a/BUILD.bazel c/go/analysis/passes/timeformat/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/timeformat/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/timeformat/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/timeformat/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/timeformat/testdata/src/b/BUILD.bazel c/go/analysis/passes/timeformat/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/timeformat/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/timeformat/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/timeformat/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unmarshal/BUILD.bazel c/go/analysis/passes/unmarshal/BUILD.bazel
--- b/go/analysis/passes/unmarshal/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unmarshal/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,35 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "unmarshal",
+    srcs = [
+        "doc.go",
+        "unmarshal.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unmarshal",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unmarshal",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "unmarshal_test",
+    srcs = ["unmarshal_test.go"],
+    deps = [
+        ":unmarshal",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/unmarshal/cmd/unmarshal/BUILD.bazel c/go/analysis/passes/unmarshal/cmd/unmarshal/BUILD.bazel
--- b/go/analysis/passes/unmarshal/cmd/unmarshal/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unmarshal/cmd/unmarshal/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "unmarshal_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unmarshal/cmd/unmarshal",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/unmarshal",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "unmarshal",
+    embed = [":unmarshal_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unmarshal/testdata/src/a/BUILD.bazel c/go/analysis/passes/unmarshal/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/unmarshal/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unmarshal/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unmarshal/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unmarshal/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/unmarshal/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/unmarshal/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unmarshal/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unmarshal/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unreachable/BUILD.bazel c/go/analysis/passes/unreachable/BUILD.bazel
--- b/go/analysis/passes/unreachable/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unreachable/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,33 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "unreachable",
+    srcs = [
+        "doc.go",
+        "unreachable.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unreachable",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unreachable",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "unreachable_test",
+    srcs = ["unreachable_test.go"],
+    deps = [
+        ":unreachable",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/unreachable/testdata/src/a/BUILD.bazel c/go/analysis/passes/unreachable/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/unreachable/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unreachable/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unreachable/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unsafeptr/BUILD.bazel c/go/analysis/passes/unsafeptr/BUILD.bazel
--- b/go/analysis/passes/unsafeptr/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unsafeptr/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "unsafeptr",
+    srcs = [
+        "doc.go",
+        "unsafeptr.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unsafeptr",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unsafeptr",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "unsafeptr_test",
+    srcs = ["unsafeptr_test.go"],
+    deps = [
+        ":unsafeptr",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/unsafeptr/testdata/src/a/BUILD.bazel c/go/analysis/passes/unsafeptr/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/unsafeptr/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unsafeptr/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = [
+        "a.go",
+        "issue40701.go",
+    ],
+    importpath = "golang.org/x/tools/go/analysis/passes/unsafeptr/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unsafeptr/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/unsafeptr/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/unsafeptr/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unsafeptr/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unsafeptr/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unusedresult/BUILD.bazel c/go/analysis/passes/unusedresult/BUILD.bazel
--- b/go/analysis/passes/unusedresult/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedresult/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,35 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "unusedresult",
+    srcs = [
+        "doc.go",
+        "unusedresult.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedresult",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/analysisinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unusedresult",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "unusedresult_test",
+    srcs = ["unusedresult_test.go"],
+    deps = [
+        ":unusedresult",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/unusedresult/cmd/unusedresult/BUILD.bazel c/go/analysis/passes/unusedresult/cmd/unusedresult/BUILD.bazel
--- b/go/analysis/passes/unusedresult/cmd/unusedresult/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedresult/cmd/unusedresult/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "unusedresult_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedresult/cmd/unusedresult",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/analysis/passes/unusedresult",
+        "//go/analysis/singlechecker",
+    ],
+)
+
+go_binary(
+    name = "unusedresult",
+    embed = [":unusedresult_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unusedresult/testdata/src/a/BUILD.bazel c/go/analysis/passes/unusedresult/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/unusedresult/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedresult/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedresult/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unusedresult/testdata/src/typeparams/BUILD.bazel c/go/analysis/passes/unusedresult/testdata/src/typeparams/BUILD.bazel
--- b/go/analysis/passes/unusedresult/testdata/src/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedresult/testdata/src/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeparams",
+    srcs = ["typeparams.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedresult/testdata/src/typeparams",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unusedresult/testdata/src/typeparams/userdefs/BUILD.bazel c/go/analysis/passes/unusedresult/testdata/src/typeparams/userdefs/BUILD.bazel
--- b/go/analysis/passes/unusedresult/testdata/src/typeparams/userdefs/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedresult/testdata/src/typeparams/userdefs/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "userdefs",
+    srcs = ["userdefs.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedresult/testdata/src/typeparams/userdefs",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":userdefs",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unusedwrite/BUILD.bazel c/go/analysis/passes/unusedwrite/BUILD.bazel
--- b/go/analysis/passes/unusedwrite/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedwrite/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "unusedwrite",
+    srcs = [
+        "doc.go",
+        "unusedwrite.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedwrite",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/buildssa",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ssa",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unusedwrite",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "unusedwrite_test",
+    srcs = ["unusedwrite_test.go"],
+    deps = [
+        ":unusedwrite",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/unusedwrite/testdata/src/a/BUILD.bazel c/go/analysis/passes/unusedwrite/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/unusedwrite/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedwrite/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["unusedwrite.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedwrite/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/unusedwrite/testdata/src/importsunsafe/BUILD.bazel c/go/analysis/passes/unusedwrite/testdata/src/importsunsafe/BUILD.bazel
--- b/go/analysis/passes/unusedwrite/testdata/src/importsunsafe/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/unusedwrite/testdata/src/importsunsafe/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "importsunsafe",
+    srcs = ["i.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/unusedwrite/testdata/src/importsunsafe",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":importsunsafe",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/usesgenerics/BUILD.bazel c/go/analysis/passes/usesgenerics/BUILD.bazel
--- b/go/analysis/passes/usesgenerics/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/usesgenerics/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "usesgenerics",
+    srcs = [
+        "doc.go",
+        "usesgenerics.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/usesgenerics",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//internal/typeparams/genericfeatures",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":usesgenerics",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "usesgenerics_test",
+    srcs = ["usesgenerics_test.go"],
+    deps = [
+        ":usesgenerics",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/usesgenerics/testdata/src/a/BUILD.bazel c/go/analysis/passes/usesgenerics/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/usesgenerics/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/usesgenerics/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/usesgenerics/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/usesgenerics/testdata/src/b/BUILD.bazel c/go/analysis/passes/usesgenerics/testdata/src/b/BUILD.bazel
--- b/go/analysis/passes/usesgenerics/testdata/src/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/usesgenerics/testdata/src/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/usesgenerics/testdata/src/b",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/usesgenerics/testdata/src/c/BUILD.bazel c/go/analysis/passes/usesgenerics/testdata/src/c/BUILD.bazel
--- b/go/analysis/passes/usesgenerics/testdata/src/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/usesgenerics/testdata/src/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/usesgenerics/testdata/src/c",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/usesgenerics/testdata/src/d/BUILD.bazel c/go/analysis/passes/usesgenerics/testdata/src/d/BUILD.bazel
--- b/go/analysis/passes/usesgenerics/testdata/src/d/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/usesgenerics/testdata/src/d/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "d",
+    srcs = ["d.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/usesgenerics/testdata/src/d",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":d",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/passes/waitgroup/BUILD.bazel c/go/analysis/passes/waitgroup/BUILD.bazel
--- b/go/analysis/passes/waitgroup/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/waitgroup/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,35 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "waitgroup",
+    srcs = [
+        "doc.go",
+        "waitgroup.go",
+    ],
+    embedsrcs = ["doc.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/waitgroup",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/analysis/passes/internal/analysisutil",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":waitgroup",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "waitgroup_test",
+    srcs = ["waitgroup_test.go"],
+    deps = [
+        ":waitgroup",
+        "//go/analysis/analysistest",
+    ],
+)
diff -urN b/go/analysis/passes/waitgroup/testdata/src/a/BUILD.bazel c/go/analysis/passes/waitgroup/testdata/src/a/BUILD.bazel
--- b/go/analysis/passes/waitgroup/testdata/src/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/passes/waitgroup/testdata/src/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/go/analysis/passes/waitgroup/testdata/src/a",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/singlechecker/BUILD.bazel c/go/analysis/singlechecker/BUILD.bazel
--- b/go/analysis/singlechecker/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/singlechecker/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "singlechecker",
+    srcs = ["singlechecker.go"],
+    importpath = "golang.org/x/tools/go/analysis/singlechecker",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/internal/analysisflags",
+        "//go/analysis/internal/checker",
+        "//go/analysis/unitchecker",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":singlechecker",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/analysis/unitchecker/BUILD.bazel c/go/analysis/unitchecker/BUILD.bazel
--- b/go/analysis/unitchecker/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/analysis/unitchecker/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,72 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "unitchecker",
+    srcs = ["unitchecker.go"],
+    importpath = "golang.org/x/tools/go/analysis/unitchecker",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/internal/analysisflags",
+        "//internal/analysisinternal",
+        "//internal/facts",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unitchecker",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "unitchecker_test",
+    srcs = [
+        "export_test.go",
+        "separate_test.go",
+        "unitchecker_test.go",
+        "vet_std_test.go",
+    ],
+    embed = [":unitchecker"],
+    deps = [
+        "//go/analysis/passes/appends",
+        "//go/analysis/passes/asmdecl",
+        "//go/analysis/passes/assign",
+        "//go/analysis/passes/atomic",
+        "//go/analysis/passes/bools",
+        "//go/analysis/passes/buildtag",
+        "//go/analysis/passes/cgocall",
+        "//go/analysis/passes/composite",
+        "//go/analysis/passes/copylock",
+        "//go/analysis/passes/defers",
+        "//go/analysis/passes/directive",
+        "//go/analysis/passes/errorsas",
+        "//go/analysis/passes/findcall",
+        "//go/analysis/passes/framepointer",
+        "//go/analysis/passes/gofix",
+        "//go/analysis/passes/hostport",
+        "//go/analysis/passes/httpresponse",
+        "//go/analysis/passes/ifaceassert",
+        "//go/analysis/passes/loopclosure",
+        "//go/analysis/passes/lostcancel",
+        "//go/analysis/passes/nilfunc",
+        "//go/analysis/passes/printf",
+        "//go/analysis/passes/shift",
+        "//go/analysis/passes/sigchanyzer",
+        "//go/analysis/passes/stdmethods",
+        "//go/analysis/passes/stdversion",
+        "//go/analysis/passes/stringintconv",
+        "//go/analysis/passes/structtag",
+        "//go/analysis/passes/testinggoroutine",
+        "//go/analysis/passes/tests",
+        "//go/analysis/passes/timeformat",
+        "//go/analysis/passes/unmarshal",
+        "//go/analysis/passes/unreachable",
+        "//go/analysis/passes/unusedresult",
+        "//go/gcexportdata",
+        "//go/packages",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/go/ast/astutil/BUILD.bazel c/go/ast/astutil/BUILD.bazel
--- b/go/ast/astutil/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ast/astutil/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "astutil",
+    srcs = [
+        "enclosing.go",
+        "imports.go",
+        "rewrite.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/go/ast/astutil",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":astutil",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "astutil_test",
+    srcs = [
+        "enclosing_test.go",
+        "imports_test.go",
+        "rewrite_test.go",
+    ],
+    embed = [":astutil"],
+)
diff -urN b/go/ast/edge/BUILD.bazel c/go/ast/edge/BUILD.bazel
--- b/go/ast/edge/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ast/edge/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "edge",
+    srcs = ["edge.go"],
+    importpath = "golang.org/x/tools/go/ast/edge",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":edge",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ast/inspector/BUILD.bazel c/go/ast/inspector/BUILD.bazel
--- b/go/ast/inspector/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ast/inspector/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "inspector",
+    srcs = [
+        "cursor.go",
+        "inspector.go",
+        "iter.go",
+        "typeof.go",
+        "walk.go",
+    ],
+    importpath = "golang.org/x/tools/go/ast/inspector",
+    visibility = ["//visibility:public"],
+    deps = ["//go/ast/edge"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":inspector",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "inspector_test",
+    srcs = [
+        "cursor_test.go",
+        "inspector_test.go",
+        "iter_test.go",
+    ],
+    deps = [
+        ":inspector",
+        "//go/ast/edge",
+    ],
+)
diff -urN b/go/buildutil/BUILD.bazel c/go/buildutil/BUILD.bazel
--- b/go/buildutil/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/buildutil/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "buildutil",
+    srcs = [
+        "allpackages.go",
+        "fakecontext.go",
+        "overlay.go",
+        "tags.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/go/buildutil",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":buildutil",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "buildutil_test",
+    srcs = [
+        "allpackages_test.go",
+        "overlay_test.go",
+        "tags_test.go",
+        "util_test.go",
+        "util_windows_test.go",
+    ],
+    deps = [
+        ":buildutil",
+        "//internal/packagestest",
+        "//internal/testenv",
+    ],
+)
diff -urN b/go/callgraph/BUILD.bazel c/go/callgraph/BUILD.bazel
--- b/go/callgraph/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "callgraph",
+    srcs = [
+        "callgraph.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/go/callgraph",
+    visibility = ["//visibility:public"],
+    deps = ["//go/ssa"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":callgraph",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "callgraph_test",
+    srcs = ["callgraph_test.go"],
+    deps = [
+        ":callgraph",
+        "//go/callgraph/cha",
+        "//go/callgraph/rta",
+        "//go/callgraph/static",
+        "//go/callgraph/vta",
+        "//go/ssa",
+        "//go/ssa/ssautil",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/go/callgraph/cha/BUILD.bazel c/go/callgraph/cha/BUILD.bazel
--- b/go/callgraph/cha/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/cha/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,158 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "cha",
+    srcs = ["cha.go"],
+    importpath = "golang.org/x/tools/go/callgraph/cha",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/callgraph",
+        "//go/callgraph/internal/chautil",
+        "//go/ssa",
+        "//go/ssa/ssautil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":cha",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "cha_test",
+    srcs = ["cha_test.go"],
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            ":cha",
+            "//go/callgraph",
+            "//go/packages",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/go/callgraph/cha/testdata/BUILD.bazel c/go/callgraph/cha/testdata/BUILD.bazel
--- b/go/callgraph/cha/testdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/cha/testdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "testdata_lib",
+    srcs = [
+        "func.go",
+        "generics.go",
+        "iface.go",
+        "issue23925.go",
+        "recv.go",
+    ],
+    importpath = "golang.org/x/tools/go/callgraph/cha/testdata",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "testdata",
+    embed = [":testdata_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/callgraph/internal/chautil/BUILD.bazel c/go/callgraph/internal/chautil/BUILD.bazel
--- b/go/callgraph/internal/chautil/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/internal/chautil/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "chautil",
+    srcs = ["lazy.go"],
+    importpath = "golang.org/x/tools/go/callgraph/internal/chautil",
+    visibility = ["//go/callgraph:__subpackages__"],
+    deps = [
+        "//go/ssa",
+        "//go/types/typeutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":chautil",
+    visibility = ["//go/callgraph:__subpackages__"],
+)
diff -urN b/go/callgraph/rta/BUILD.bazel c/go/callgraph/rta/BUILD.bazel
--- b/go/callgraph/rta/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/rta/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,132 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "rta",
+    srcs = ["rta.go"],
+    importpath = "golang.org/x/tools/go/callgraph/rta",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/callgraph",
+        "//go/ssa",
+        "//go/types/typeutil",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":rta",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "rta_test",
+    srcs = ["rta_test.go"],
+    data = glob(["testdata/**"]),
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            ":rta",
+            "//go/callgraph",
+            "//go/ssa",
+            "//go/ssa/ssautil",
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/go/callgraph/static/BUILD.bazel c/go/callgraph/static/BUILD.bazel
--- b/go/callgraph/static/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/static/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,31 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "static",
+    srcs = ["static.go"],
+    importpath = "golang.org/x/tools/go/callgraph/static",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/callgraph",
+        "//go/ssa",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":static",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "static_test",
+    srcs = ["static_test.go"],
+    deps = [
+        ":static",
+        "//go/callgraph",
+        "//go/ssa",
+        "//go/ssa/ssautil",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/go/callgraph/vta/BUILD.bazel c/go/callgraph/vta/BUILD.bazel
--- b/go/callgraph/vta/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/vta/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,54 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "vta",
+    srcs = [
+        "graph.go",
+        "initial.go",
+        "propagation.go",
+        "utils.go",
+        "vta.go",
+    ],
+    importpath = "golang.org/x/tools/go/callgraph/vta",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/callgraph",
+        "//go/callgraph/internal/chautil",
+        "//go/callgraph/vta/internal/trie",
+        "//go/ssa",
+        "//go/types/typeutil",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":vta",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "vta_test",
+    srcs = [
+        "graph_test.go",
+        "helpers_test.go",
+        "propagation_test.go",
+        "vta_test.go",
+    ],
+    embed = [":vta"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/analysistest",
+        "//go/analysis/passes/buildssa",
+        "//go/callgraph",
+        "//go/callgraph/cha",
+        "//go/packages",
+        "//go/ssa",
+        "//go/ssa/ssautil",
+        "//go/types/typeutil",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+        "@com_github_google_go_cmp//cmp:go_default_library",
+    ],
+)
diff -urN b/go/callgraph/vta/internal/trie/BUILD.bazel c/go/callgraph/vta/internal/trie/BUILD.bazel
--- b/go/callgraph/vta/internal/trie/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/vta/internal/trie/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "trie",
+    srcs = [
+        "bits.go",
+        "builder.go",
+        "scope.go",
+        "trie.go",
+    ],
+    importpath = "golang.org/x/tools/go/callgraph/vta/internal/trie",
+    visibility = ["//go/callgraph/vta:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":trie",
+    visibility = ["//go/callgraph/vta:__subpackages__"],
+)
+
+go_test(
+    name = "trie_test",
+    srcs = [
+        "bits_test.go",
+        "op_test.go",
+        "trie_test.go",
+    ],
+    embed = [":trie"],
+)
diff -urN b/go/callgraph/vta/testdata/src/d/BUILD.bazel c/go/callgraph/vta/testdata/src/d/BUILD.bazel
--- b/go/callgraph/vta/testdata/src/d/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/vta/testdata/src/d/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "d",
+    srcs = ["d.go"],
+    importpath = "golang.org/x/tools/go/callgraph/vta/testdata/src/d",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":d",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/callgraph/vta/testdata/src/t/BUILD.bazel c/go/callgraph/vta/testdata/src/t/BUILD.bazel
--- b/go/callgraph/vta/testdata/src/t/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/callgraph/vta/testdata/src/t/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "t",
+    srcs = ["t.go"],
+    importpath = "golang.org/x/tools/go/callgraph/vta/testdata/src/t",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":t",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/cfg/BUILD.bazel c/go/cfg/BUILD.bazel
--- b/go/cfg/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/cfg/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "cfg",
+    srcs = [
+        "builder.go",
+        "cfg.go",
+    ],
+    importpath = "golang.org/x/tools/go/cfg",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":cfg",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "cfg_test",
+    srcs = ["cfg_test.go"],
+    deps = [
+        ":cfg",
+        "//go/packages",
+        "//internal/testenv",
+    ],
+)
diff -urN b/go/gccgoexportdata/BUILD.bazel c/go/gccgoexportdata/BUILD.bazel
--- b/go/gccgoexportdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/gccgoexportdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "gccgoexportdata",
+    srcs = ["gccgoexportdata.go"],
+    importpath = "golang.org/x/tools/go/gccgoexportdata",
+    visibility = ["//visibility:public"],
+    deps = ["//go/internal/gccgoimporter"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gccgoexportdata",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "gccgoexportdata_test",
+    srcs = ["gccgoexportdata_test.go"],
+    data = glob(["testdata/**"]),
+    deps = [":gccgoexportdata"],
+)
diff -urN b/go/gcexportdata/BUILD.bazel c/go/gcexportdata/BUILD.bazel
--- b/go/gcexportdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/gcexportdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,59 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "gcexportdata",
+    srcs = [
+        "gcexportdata.go",
+        "importer.go",
+    ],
+    importpath = "golang.org/x/tools/go/gcexportdata",
+    visibility = ["//visibility:public"],
+    deps = ["//internal/gcimporter"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gcexportdata",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "gcexportdata_test",
+    srcs = ["example_test.go"],
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            ":gcexportdata",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            ":gcexportdata",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/go/internal/cgo/BUILD.bazel c/go/internal/cgo/BUILD.bazel
--- b/go/internal/cgo/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/internal/cgo/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "cgo",
+    srcs = [
+        "cgo.go",
+        "cgo_pkgconfig.go",
+    ],
+    importpath = "golang.org/x/tools/go/internal/cgo",
+    visibility = ["//go:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":cgo",
+    visibility = ["//go:__subpackages__"],
+)
diff -urN b/go/internal/gccgoimporter/BUILD.bazel c/go/internal/gccgoimporter/BUILD.bazel
--- b/go/internal/gccgoimporter/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/internal/gccgoimporter/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "gccgoimporter",
+    srcs = [
+        "ar.go",
+        "backdoor.go",
+        "gccgoinstallation.go",
+        "importer.go",
+        "newInterface10.go",
+        "newInterface11.go",
+        "parser.go",
+    ],
+    importpath = "golang.org/x/tools/go/internal/gccgoimporter",
+    visibility = ["//go:__subpackages__"],
+    deps = ["//internal/typesinternal"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gccgoimporter",
+    visibility = ["//go:__subpackages__"],
+)
+
+go_test(
+    name = "gccgoimporter_test",
+    srcs = [
+        "gccgoinstallation_test.go",
+        "importer_test.go",
+        "parser_test.go",
+        "testenv_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    embed = [":gccgoimporter"],
+    deps = ["//internal/testenv"],
+)
diff -urN b/go/loader/BUILD.bazel c/go/loader/BUILD.bazel
--- b/go/loader/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/loader/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "loader",
+    srcs = [
+        "doc.go",
+        "loader.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/go/loader",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/ast/astutil",
+        "//go/buildutil",
+        "//go/internal/cgo",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":loader",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "loader_test",
+    srcs = [
+        "loader_test.go",
+        "stdlib_test.go",
+    ],
+    deps = [
+        ":loader",
+        "//go/buildutil",
+        "//internal/testenv",
+    ],
+)
diff -urN b/go/loader/testdata/BUILD.bazel c/go/loader/testdata/BUILD.bazel
--- b/go/loader/testdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/loader/testdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "testdata",
+    srcs = [
+        "a.go",
+        "b.go",
+        "badpkgdecl.go",
+    ],
+    importpath = "golang.org/x/tools/go/loader/testdata",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":testdata",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/loader/testdata/issue46877/BUILD.bazel c/go/loader/testdata/issue46877/BUILD.bazel
--- b/go/loader/testdata/issue46877/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/loader/testdata/issue46877/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "issue46877",
+    srcs = [
+        "x.go",
+        "x.h",
+    ],
+    cgo = True,
+    importpath = "golang.org/x/tools/go/loader/testdata/issue46877",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":issue46877",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/packages/BUILD.bazel c/go/packages/BUILD.bazel
--- b/go/packages/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/packages/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,48 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "packages",
+    srcs = [
+        "doc.go",
+        "external.go",
+        "golist.go",
+        "golist_overlay.go",
+        "loadmode_string.go",
+        "packages.go",
+        "visit.go",
+    ],
+    importpath = "golang.org/x/tools/go/packages",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/gcexportdata",
+        "//internal/gocommand",
+        "//internal/packagesinternal",
+        "//internal/typesinternal",
+        "@org_golang_x_sync//errgroup:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":packages",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "packages_test",
+    srcs = [
+        "example_test.go",
+        "overlay_test.go",
+        "packages_test.go",
+        "stdlib_test.go",
+    ],
+    deps = [
+        ":packages",
+        "//internal/packagesinternal",
+        "//internal/packagestest",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+        "@com_github_google_go_cmp//cmp:go_default_library",
+    ],
+)
diff -urN b/go/packages/gopackages/BUILD.bazel c/go/packages/gopackages/BUILD.bazel
--- b/go/packages/gopackages/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/packages/gopackages/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "gopackages_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/go/packages/gopackages",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/packages",
+        "//go/types/typeutil",
+        "//internal/drivertest",
+        "//internal/tool",
+    ],
+)
+
+go_binary(
+    name = "gopackages",
+    embed = [":gopackages_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/packages/internal/linecount/BUILD.bazel c/go/packages/internal/linecount/BUILD.bazel
--- b/go/packages/internal/linecount/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/packages/internal/linecount/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "linecount_lib",
+    srcs = ["linecount.go"],
+    importpath = "golang.org/x/tools/go/packages/internal/linecount",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/packages",
+        "@org_golang_x_sync//errgroup:go_default_library",
+    ],
+)
+
+go_binary(
+    name = "linecount",
+    embed = [":linecount_lib"],
+    visibility = ["//go/packages:__subpackages__"],
+)
diff -urN b/go/packages/internal/nodecount/BUILD.bazel c/go/packages/internal/nodecount/BUILD.bazel
--- b/go/packages/internal/nodecount/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/packages/internal/nodecount/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "nodecount_lib",
+    srcs = ["nodecount.go"],
+    importpath = "golang.org/x/tools/go/packages/internal/nodecount",
+    visibility = ["//visibility:private"],
+    deps = ["//go/packages"],
+)
+
+go_binary(
+    name = "nodecount",
+    embed = [":nodecount_lib"],
+    visibility = ["//go/packages:__subpackages__"],
+)
diff -urN b/go/ssa/BUILD.bazel c/go/ssa/BUILD.bazel
--- b/go/ssa/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,75 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "ssa",
+    srcs = [
+        "block.go",
+        "blockopt.go",
+        "builder.go",
+        "const.go",
+        "create.go",
+        "doc.go",
+        "dom.go",
+        "emit.go",
+        "func.go",
+        "instantiate.go",
+        "lift.go",
+        "lvalue.go",
+        "methods.go",
+        "mode.go",
+        "print.go",
+        "sanity.go",
+        "source.go",
+        "ssa.go",
+        "subst.go",
+        "task.go",
+        "typeset.go",
+        "util.go",
+        "wrappers.go",
+    ],
+    importpath = "golang.org/x/tools/go/ssa",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/types/typeutil",
+        "//internal/aliases",
+        "//internal/typeparams",
+        "//internal/typesinternal",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":ssa",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "ssa_test",
+    srcs = [
+        "builder_generic_test.go",
+        "builder_test.go",
+        "const_test.go",
+        "dom_test.go",
+        "example_test.go",
+        "instantiate_test.go",
+        "methods_test.go",
+        "source_test.go",
+        "stdlib_test.go",
+        "subst_test.go",
+        "testutil_test.go",
+    ],
+    embed = [":ssa"],
+    deps = [
+        "//go/analysis/analysistest",
+        "//go/ast/astutil",
+        "//go/loader",
+        "//go/packages",
+        "//go/ssa/ssautil",
+        "//internal/expect",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+        "@org_golang_x_sync//errgroup:go_default_library",
+    ],
+)
diff -urN b/go/ssa/interp/BUILD.bazel c/go/ssa/interp/BUILD.bazel
--- b/go/ssa/interp/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,41 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "interp",
+    srcs = [
+        "external.go",
+        "interp.go",
+        "map.go",
+        "ops.go",
+        "reflect.go",
+        "value.go",
+    ],
+    importpath = "golang.org/x/tools/go/ssa/interp",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/ssa",
+        "//go/types/typeutil",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":interp",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "interp_test",
+    srcs = [
+        "interp_test.go",
+        "rangefunc_test.go",
+    ],
+    deps = [
+        ":interp",
+        "//go/loader",
+        "//go/ssa",
+        "//go/ssa/ssautil",
+        "//internal/testenv",
+    ],
+)
diff -urN b/go/ssa/interp/testdata/fixedbugs/BUILD.bazel c/go/ssa/interp/testdata/fixedbugs/BUILD.bazel
--- b/go/ssa/interp/testdata/fixedbugs/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/fixedbugs/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "fixedbugs_lib",
+    srcs = [
+        "issue52342.go",
+        "issue52835.go",
+        "issue55086.go",
+        "issue55115.go",
+        "issue66783.go",
+        "issue69298.go",
+        "issue69929.go",
+    ],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/fixedbugs",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "fixedbugs",
+    embed = [":fixedbugs_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/encoding/BUILD.bazel c/go/ssa/interp/testdata/src/encoding/BUILD.bazel
--- b/go/ssa/interp/testdata/src/encoding/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/encoding/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "encoding",
+    srcs = ["encoding.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/encoding",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":encoding",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/errors/BUILD.bazel c/go/ssa/interp/testdata/src/errors/BUILD.bazel
--- b/go/ssa/interp/testdata/src/errors/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/errors/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "errors",
+    srcs = ["errors.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/errors",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":errors",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/fmt/BUILD.bazel c/go/ssa/interp/testdata/src/fmt/BUILD.bazel
--- b/go/ssa/interp/testdata/src/fmt/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/fmt/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "fmt",
+    srcs = ["fmt.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/fmt",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fmt",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/io/BUILD.bazel c/go/ssa/interp/testdata/src/io/BUILD.bazel
--- b/go/ssa/interp/testdata/src/io/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/io/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "io",
+    srcs = ["io.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/io",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":io",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/log/BUILD.bazel c/go/ssa/interp/testdata/src/log/BUILD.bazel
--- b/go/ssa/interp/testdata/src/log/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/log/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "log",
+    srcs = ["log.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/log",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":log",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/math/BUILD.bazel c/go/ssa/interp/testdata/src/math/BUILD.bazel
--- b/go/ssa/interp/testdata/src/math/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/math/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "math",
+    srcs = ["math.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/math",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":math",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/os/BUILD.bazel c/go/ssa/interp/testdata/src/os/BUILD.bazel
--- b/go/ssa/interp/testdata/src/os/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/os/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "os",
+    srcs = ["os.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/os",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":os",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/reflect/BUILD.bazel c/go/ssa/interp/testdata/src/reflect/BUILD.bazel
--- b/go/ssa/interp/testdata/src/reflect/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/reflect/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,17 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "reflect",
+    srcs = [
+        "deepequal.go",
+        "reflect.go",
+    ],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/reflect",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":reflect",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/runtime/BUILD.bazel c/go/ssa/interp/testdata/src/runtime/BUILD.bazel
--- b/go/ssa/interp/testdata/src/runtime/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/runtime/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "runtime",
+    srcs = ["runtime.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/runtime",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":runtime",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/sort/BUILD.bazel c/go/ssa/interp/testdata/src/sort/BUILD.bazel
--- b/go/ssa/interp/testdata/src/sort/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/sort/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "sort",
+    srcs = ["sort.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/sort",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":sort",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/strconv/BUILD.bazel c/go/ssa/interp/testdata/src/strconv/BUILD.bazel
--- b/go/ssa/interp/testdata/src/strconv/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/strconv/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "strconv",
+    srcs = ["strconv.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/strconv",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":strconv",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/strings/BUILD.bazel c/go/ssa/interp/testdata/src/strings/BUILD.bazel
--- b/go/ssa/interp/testdata/src/strings/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/strings/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "strings",
+    srcs = ["strings.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/strings",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":strings",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/sync/BUILD.bazel c/go/ssa/interp/testdata/src/sync/BUILD.bazel
--- b/go/ssa/interp/testdata/src/sync/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/sync/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "sync",
+    srcs = ["sync.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/sync",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":sync",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/time/BUILD.bazel c/go/ssa/interp/testdata/src/time/BUILD.bazel
--- b/go/ssa/interp/testdata/src/time/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/time/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "time",
+    srcs = ["time.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/time",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":time",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/unicode/utf8/BUILD.bazel c/go/ssa/interp/testdata/src/unicode/utf8/BUILD.bazel
--- b/go/ssa/interp/testdata/src/unicode/utf8/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/unicode/utf8/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "utf8",
+    srcs = ["utf8.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/unicode/utf8",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":utf8",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/interp/testdata/src/unsafe/BUILD.bazel c/go/ssa/interp/testdata/src/unsafe/BUILD.bazel
--- b/go/ssa/interp/testdata/src/unsafe/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/interp/testdata/src/unsafe/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "unsafe",
+    srcs = ["unsafe.go"],
+    importpath = "golang.org/x/tools/go/ssa/interp/testdata/src/unsafe",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unsafe",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/ssautil/BUILD.bazel c/go/ssa/ssautil/BUILD.bazel
--- b/go/ssa/ssautil/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/ssautil/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,96 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "ssautil",
+    srcs = [
+        "deprecated.go",
+        "load.go",
+        "switch.go",
+        "visit.go",
+    ],
+    importpath = "golang.org/x/tools/go/ssa/ssautil",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/loader",
+        "//go/packages",
+        "//go/ssa",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":ssautil",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "ssautil_test",
+    srcs = [
+        "deprecated_test.go",
+        "load_test.go",
+        "switch_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    deps = [
+        ":ssautil",
+        "//go/loader",
+        "//go/packages",
+        "//go/ssa",
+        "//internal/packagestest",
+        "//internal/testenv",
+    ] + select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            "//internal/testfiles",
+            "//txtar",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/go/ssa/testdata/BUILD.bazel c/go/ssa/testdata/BUILD.bazel
--- b/go/ssa/testdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "testdata_lib",
+    srcs = [
+        "objlookup.go",
+        "structconv.go",
+        "valueforexpr.go",
+    ],
+    importpath = "golang.org/x/tools/go/ssa/testdata",
+    visibility = ["//visibility:private"],
+)
+
+go_binary(
+    name = "testdata",
+    embed = [":testdata_lib"],
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/fixedbugs/BUILD.bazel c/go/ssa/testdata/fixedbugs/BUILD.bazel
--- b/go/ssa/testdata/fixedbugs/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/fixedbugs/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "fixedbugs",
+    srcs = ["issue73594.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/fixedbugs",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fixedbugs",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/bytes/BUILD.bazel c/go/ssa/testdata/src/bytes/BUILD.bazel
--- b/go/ssa/testdata/src/bytes/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/bytes/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "bytes",
+    srcs = ["bytes.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/bytes",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":bytes",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/context/BUILD.bazel c/go/ssa/testdata/src/context/BUILD.bazel
--- b/go/ssa/testdata/src/context/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/context/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "context",
+    srcs = ["context.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/context",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":context",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/encoding/BUILD.bazel c/go/ssa/testdata/src/encoding/BUILD.bazel
--- b/go/ssa/testdata/src/encoding/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/encoding/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "encoding",
+    srcs = ["encoding.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/encoding",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":encoding",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/encoding/json/BUILD.bazel c/go/ssa/testdata/src/encoding/json/BUILD.bazel
--- b/go/ssa/testdata/src/encoding/json/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/encoding/json/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "json",
+    srcs = ["json.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/encoding/json",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":json",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/encoding/xml/BUILD.bazel c/go/ssa/testdata/src/encoding/xml/BUILD.bazel
--- b/go/ssa/testdata/src/encoding/xml/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/encoding/xml/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "xml",
+    srcs = ["xml.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/encoding/xml",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":xml",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/errors/BUILD.bazel c/go/ssa/testdata/src/errors/BUILD.bazel
--- b/go/ssa/testdata/src/errors/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/errors/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "errors",
+    srcs = ["errors.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/errors",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":errors",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/fmt/BUILD.bazel c/go/ssa/testdata/src/fmt/BUILD.bazel
--- b/go/ssa/testdata/src/fmt/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/fmt/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "fmt",
+    srcs = ["fmt.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/fmt",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fmt",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/io/BUILD.bazel c/go/ssa/testdata/src/io/BUILD.bazel
--- b/go/ssa/testdata/src/io/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/io/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "io",
+    srcs = ["io.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/io",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":io",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/log/BUILD.bazel c/go/ssa/testdata/src/log/BUILD.bazel
--- b/go/ssa/testdata/src/log/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/log/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "log",
+    srcs = ["log.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/log",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":log",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/math/BUILD.bazel c/go/ssa/testdata/src/math/BUILD.bazel
--- b/go/ssa/testdata/src/math/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/math/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "math",
+    srcs = ["math.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/math",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":math",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/os/BUILD.bazel c/go/ssa/testdata/src/os/BUILD.bazel
--- b/go/ssa/testdata/src/os/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/os/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "os",
+    srcs = ["os.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/os",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":os",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/reflect/BUILD.bazel c/go/ssa/testdata/src/reflect/BUILD.bazel
--- b/go/ssa/testdata/src/reflect/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/reflect/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "reflect",
+    srcs = ["reflect.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/reflect",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":reflect",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/runtime/BUILD.bazel c/go/ssa/testdata/src/runtime/BUILD.bazel
--- b/go/ssa/testdata/src/runtime/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/runtime/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "runtime",
+    srcs = ["runtime.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/runtime",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":runtime",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/sort/BUILD.bazel c/go/ssa/testdata/src/sort/BUILD.bazel
--- b/go/ssa/testdata/src/sort/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/sort/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "sort",
+    srcs = ["sort.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/sort",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":sort",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/strconv/BUILD.bazel c/go/ssa/testdata/src/strconv/BUILD.bazel
--- b/go/ssa/testdata/src/strconv/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/strconv/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "strconv",
+    srcs = ["strconv.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/strconv",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":strconv",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/strings/BUILD.bazel c/go/ssa/testdata/src/strings/BUILD.bazel
--- b/go/ssa/testdata/src/strings/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/strings/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "strings",
+    srcs = ["strings.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/strings",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":strings",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/sync/atomic/BUILD.bazel c/go/ssa/testdata/src/sync/atomic/BUILD.bazel
--- b/go/ssa/testdata/src/sync/atomic/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/sync/atomic/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "atomic",
+    srcs = ["atomic.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/sync/atomic",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":atomic",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/sync/BUILD.bazel c/go/ssa/testdata/src/sync/BUILD.bazel
--- b/go/ssa/testdata/src/sync/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/sync/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "sync",
+    srcs = ["sync.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/sync",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":sync",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/time/BUILD.bazel c/go/ssa/testdata/src/time/BUILD.bazel
--- b/go/ssa/testdata/src/time/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/time/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "time",
+    srcs = ["time.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/time",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":time",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/ssa/testdata/src/unsafe/BUILD.bazel c/go/ssa/testdata/src/unsafe/BUILD.bazel
--- b/go/ssa/testdata/src/unsafe/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/ssa/testdata/src/unsafe/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "unsafe",
+    srcs = ["unsafe.go"],
+    importpath = "golang.org/x/tools/go/ssa/testdata/src/unsafe",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":unsafe",
+    visibility = ["//visibility:public"],
+)
diff -urN b/go/types/internal/play/BUILD.bazel c/go/types/internal/play/BUILD.bazel
--- b/go/types/internal/play/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/types/internal/play/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,21 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "play_lib",
+    srcs = ["play.go"],
+    importpath = "golang.org/x/tools/go/types/internal/play",
+    visibility = ["//visibility:private"],
+    deps = [
+        "//go/ast/astutil",
+        "//go/ast/inspector",
+        "//go/packages",
+        "//go/types/typeutil",
+        "//internal/typeparams",
+    ],
+)
+
+go_binary(
+    name = "play",
+    embed = [":play_lib"],
+    visibility = ["//go/types:__subpackages__"],
+)
diff -urN b/go/types/objectpath/BUILD.bazel c/go/types/objectpath/BUILD.bazel
--- b/go/types/objectpath/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/types/objectpath/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "objectpath",
+    srcs = ["objectpath.go"],
+    importpath = "golang.org/x/tools/go/types/objectpath",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//internal/aliases",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":objectpath",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "objectpath_test",
+    srcs = [
+        "objectpath_go118_test.go",
+        "objectpath_test.go",
+    ],
+    deps = [
+        ":objectpath",
+        "//go/gcexportdata",
+        "//go/packages",
+        "//internal/aliases",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/go/types/typeutil/BUILD.bazel c/go/types/typeutil/BUILD.bazel
--- b/go/types/typeutil/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/go/types/typeutil/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,37 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "typeutil",
+    srcs = [
+        "callee.go",
+        "imports.go",
+        "map.go",
+        "methodsetcache.go",
+        "ui.go",
+    ],
+    importpath = "golang.org/x/tools/go/types/typeutil",
+    visibility = ["//visibility:public"],
+    deps = ["//internal/typeparams"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeutil",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "typeutil_test",
+    srcs = [
+        "callee_test.go",
+        "example_test.go",
+        "imports_test.go",
+        "map_test.go",
+        "ui_test.go",
+    ],
+    deps = [
+        ":typeutil",
+        "//go/packages",
+        "//internal/testenv",
+    ],
+)
diff -urN b/imports/BUILD.bazel c/imports/BUILD.bazel
--- b/imports/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/imports/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "imports",
+    srcs = ["forward.go"],
+    importpath = "golang.org/x/tools/imports",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//internal/gocommand",
+        "//internal/imports",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":imports",
+    visibility = ["//visibility:public"],
+)
diff -urN b/internal/aliases/BUILD.bazel c/internal/aliases/BUILD.bazel
--- b/internal/aliases/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/aliases/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,26 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "aliases",
+    srcs = [
+        "aliases.go",
+        "aliases_go122.go",
+    ],
+    importpath = "golang.org/x/tools/internal/aliases",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":aliases",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "aliases_test",
+    srcs = ["aliases_test.go"],
+    deps = [
+        ":aliases",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/analysisinternal/BUILD.bazel c/internal/analysisinternal/BUILD.bazel
--- b/internal/analysisinternal/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/analysisinternal/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "analysisinternal",
+    srcs = [
+        "analysis.go",
+        "extractdoc.go",
+    ],
+    importpath = "golang.org/x/tools/internal/analysisinternal",
+    visibility = ["//:__subpackages__"],
+    deps = ["//go/analysis"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":analysisinternal",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "analysisinternal_test",
+    srcs = [
+        "analysis_test.go",
+        "extractdoc_test.go",
+    ],
+    deps = [":analysisinternal"],
+)
diff -urN b/internal/analysisinternal/generated/BUILD.bazel c/internal/analysisinternal/generated/BUILD.bazel
--- b/internal/analysisinternal/generated/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/analysisinternal/generated/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "generated",
+    srcs = ["generated.go"],
+    importpath = "golang.org/x/tools/internal/analysisinternal/generated",
+    visibility = ["//:__subpackages__"],
+    deps = ["//go/analysis"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":generated",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/analysisinternal/typeindex/BUILD.bazel c/internal/analysisinternal/typeindex/BUILD.bazel
--- b/internal/analysisinternal/typeindex/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/analysisinternal/typeindex/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "typeindex",
+    srcs = ["typeindex.go"],
+    importpath = "golang.org/x/tools/internal/analysisinternal/typeindex",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/analysis",
+        "//go/analysis/passes/inspect",
+        "//go/ast/inspector",
+        "//internal/typesinternal/typeindex",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeindex",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/astutil/BUILD.bazel c/internal/astutil/BUILD.bazel
--- b/internal/astutil/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/astutil/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,44 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "astutil",
+    srcs = [
+        "clone.go",
+        "comment.go",
+        "equal.go",
+        "fields.go",
+        "purge.go",
+        "stringlit.go",
+        "unpack.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/internal/astutil",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/ast/edge",
+        "//go/ast/inspector",
+        "//internal/moreiters",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":astutil",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "astutil_test",
+    srcs = [
+        "comment_test.go",
+        "fields_test.go",
+        "purge_test.go",
+        "util_test.go",
+    ],
+    deps = [
+        ":astutil",
+        "//go/packages",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/bisect/BUILD.bazel c/internal/bisect/BUILD.bazel
--- b/internal/bisect/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/bisect/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "bisect",
+    srcs = ["bisect.go"],
+    importpath = "golang.org/x/tools/internal/bisect",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":bisect",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "bisect_test",
+    srcs = ["bisect_test.go"],
+    embed = [":bisect"],
+)
diff -urN b/internal/diff/BUILD.bazel c/internal/diff/BUILD.bazel
--- b/internal/diff/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/diff/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "diff",
+    srcs = [
+        "diff.go",
+        "merge.go",
+        "ndiff.go",
+        "unified.go",
+    ],
+    importpath = "golang.org/x/tools/internal/diff",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/diff/lcs"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":diff",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "diff_test",
+    srcs = [
+        "diff_test.go",
+        "export_test.go",
+        "merge_test.go",
+    ],
+    embed = [":diff"],
+    deps = [
+        "//internal/diff/difftest",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/diff/difftest/BUILD.bazel c/internal/diff/difftest/BUILD.bazel
--- b/internal/diff/difftest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/diff/difftest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "difftest",
+    srcs = ["difftest.go"],
+    importpath = "golang.org/x/tools/internal/diff/difftest",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/diff"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":difftest",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "difftest_test",
+    srcs = ["difftest_test.go"],
+    deps = [
+        ":difftest",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/diff/lcs/BUILD.bazel c/internal/diff/lcs/BUILD.bazel
--- b/internal/diff/lcs/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/diff/lcs/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "lcs",
+    srcs = [
+        "common.go",
+        "doc.go",
+        "labels.go",
+        "old.go",
+        "sequence.go",
+    ],
+    importpath = "golang.org/x/tools/internal/diff/lcs",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":lcs",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "lcs_test",
+    srcs = [
+        "common_test.go",
+        "old_test.go",
+    ],
+    embed = [":lcs"],
+)
diff -urN b/internal/diff/myers/BUILD.bazel c/internal/diff/myers/BUILD.bazel
--- b/internal/diff/myers/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/diff/myers/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "myers",
+    srcs = ["diff.go"],
+    importpath = "golang.org/x/tools/internal/diff/myers",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/diff"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":myers",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "myers_test",
+    srcs = ["diff_test.go"],
+    deps = [
+        ":myers",
+        "//internal/diff/difftest",
+    ],
+)
diff -urN b/internal/diffp/BUILD.bazel c/internal/diffp/BUILD.bazel
--- b/internal/diffp/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/diffp/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "diffp",
+    srcs = ["diff.go"],
+    importpath = "golang.org/x/tools/internal/diffp",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":diffp",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "diffp_test",
+    srcs = ["diff_test.go"],
+    data = glob(["testdata/**"]),
+    embed = [":diffp"],
+    deps = ["//txtar"],
+)
diff -urN b/internal/drivertest/BUILD.bazel c/internal/drivertest/BUILD.bazel
--- b/internal/drivertest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/drivertest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,30 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "drivertest",
+    srcs = ["driver.go"],
+    importpath = "golang.org/x/tools/internal/drivertest",
+    visibility = ["//:__subpackages__"],
+    deps = ["//go/packages"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":drivertest",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "drivertest_test",
+    srcs = ["driver_test.go"],
+    deps = [
+        ":drivertest",
+        "//go/packages",
+        "//internal/diff",
+        "//internal/diff/myers",
+        "//internal/packagesinternal",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/internal/edit/BUILD.bazel c/internal/edit/BUILD.bazel
--- b/internal/edit/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/edit/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "edit",
+    srcs = ["edit.go"],
+    importpath = "golang.org/x/tools/internal/edit",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":edit",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "edit_test",
+    srcs = ["edit_test.go"],
+    embed = [":edit"],
+)
diff -urN b/internal/event/BUILD.bazel c/internal/event/BUILD.bazel
--- b/internal/event/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "event",
+    srcs = [
+        "doc.go",
+        "event.go",
+    ],
+    importpath = "golang.org/x/tools/internal/event",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event/core",
+        "//internal/event/keys",
+        "//internal/event/label",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":event",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "event_test",
+    srcs = ["bench_test.go"],
+    deps = [
+        ":event",
+        "//internal/event/core",
+        "//internal/event/export",
+        "//internal/event/keys",
+        "//internal/event/label",
+    ],
+)
diff -urN b/internal/event/core/BUILD.bazel c/internal/event/core/BUILD.bazel
--- b/internal/event/core/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/core/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "core",
+    srcs = [
+        "event.go",
+        "export.go",
+        "fast.go",
+    ],
+    importpath = "golang.org/x/tools/internal/event/core",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event/keys",
+        "//internal/event/label",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":core",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/event/export/BUILD.bazel c/internal/event/export/BUILD.bazel
--- b/internal/event/export/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/export/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,38 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "export",
+    srcs = [
+        "id.go",
+        "labels.go",
+        "log.go",
+        "printer.go",
+        "trace.go",
+    ],
+    importpath = "golang.org/x/tools/internal/event/export",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event",
+        "//internal/event/core",
+        "//internal/event/keys",
+        "//internal/event/label",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":export",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "export_test",
+    srcs = ["log_test.go"],
+    deps = [
+        ":export",
+        "//internal/event",
+        "//internal/event/core",
+        "//internal/event/keys",
+        "//internal/event/label",
+    ],
+)
diff -urN b/internal/event/export/eventtest/BUILD.bazel c/internal/event/export/eventtest/BUILD.bazel
--- b/internal/event/export/eventtest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/export/eventtest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "eventtest",
+    srcs = ["eventtest.go"],
+    importpath = "golang.org/x/tools/internal/event/export/eventtest",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event",
+        "//internal/event/core",
+        "//internal/event/export",
+        "//internal/event/label",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":eventtest",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/event/export/metric/BUILD.bazel c/internal/event/export/metric/BUILD.bazel
--- b/internal/event/export/metric/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/export/metric/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "metric",
+    srcs = [
+        "data.go",
+        "exporter.go",
+        "info.go",
+    ],
+    importpath = "golang.org/x/tools/internal/event/export/metric",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event",
+        "//internal/event/core",
+        "//internal/event/keys",
+        "//internal/event/label",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":metric",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/event/export/prometheus/BUILD.bazel c/internal/event/export/prometheus/BUILD.bazel
--- b/internal/event/export/prometheus/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/export/prometheus/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "prometheus",
+    srcs = ["prometheus.go"],
+    importpath = "golang.org/x/tools/internal/event/export/prometheus",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event",
+        "//internal/event/core",
+        "//internal/event/export/metric",
+        "//internal/event/label",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":prometheus",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/event/keys/BUILD.bazel c/internal/event/keys/BUILD.bazel
--- b/internal/event/keys/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/keys/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,25 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "keys",
+    srcs = [
+        "keys.go",
+        "standard.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/internal/event/keys",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/event/label"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":keys",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "keys_test",
+    srcs = ["util_test.go"],
+    embed = [":keys"],
+)
diff -urN b/internal/event/label/BUILD.bazel c/internal/event/label/BUILD.bazel
--- b/internal/event/label/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/event/label/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,23 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "label",
+    srcs = ["label.go"],
+    importpath = "golang.org/x/tools/internal/event/label",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":label",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "label_test",
+    srcs = ["label_test.go"],
+    deps = [
+        ":label",
+        "//internal/event/keys",
+    ],
+)
diff -urN b/internal/expect/BUILD.bazel c/internal/expect/BUILD.bazel
--- b/internal/expect/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/expect/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "expect",
+    srcs = [
+        "expect.go",
+        "extract.go",
+    ],
+    importpath = "golang.org/x/tools/internal/expect",
+    visibility = ["//:__subpackages__"],
+    deps = ["@org_golang_x_mod//modfile:go_default_library"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":expect",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "expect_test",
+    srcs = ["expect_test.go"],
+    deps = [":expect"],
+)
diff -urN b/internal/expect/testdata/BUILD.bazel c/internal/expect/testdata/BUILD.bazel
--- b/internal/expect/testdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/expect/testdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "testdata",
+    srcs = ["test.go"],
+    importpath = "golang.org/x/tools/internal/expect/testdata",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":testdata",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/facts/BUILD.bazel c/internal/facts/BUILD.bazel
--- b/internal/facts/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/facts/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "facts",
+    srcs = [
+        "facts.go",
+        "imports.go",
+    ],
+    importpath = "golang.org/x/tools/internal/facts",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/analysis",
+        "//go/types/objectpath",
+        "//internal/aliases",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":facts",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "facts_test",
+    srcs = ["facts_test.go"],
+    deps = [
+        ":facts",
+        "//go/analysis/analysistest",
+        "//go/packages",
+        "//internal/aliases",
+        "//internal/testenv",
+        "//internal/typesinternal",
+    ],
+)
diff -urN b/internal/fmtstr/BUILD.bazel c/internal/fmtstr/BUILD.bazel
--- b/internal/fmtstr/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/fmtstr/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "fmtstr",
+    srcs = ["parse.go"],
+    importpath = "golang.org/x/tools/internal/fmtstr",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":fmtstr",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/BUILD.bazel c/internal/gcimporter/BUILD.bazel
--- b/internal/gcimporter/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,51 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "gcimporter",
+    srcs = [
+        "bimport.go",
+        "exportdata.go",
+        "gcimporter.go",
+        "iexport.go",
+        "iimport.go",
+        "predeclared.go",
+        "support.go",
+        "ureader_yes.go",
+    ],
+    importpath = "golang.org/x/tools/internal/gcimporter",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/types/objectpath",
+        "//internal/aliases",
+        "//internal/pkgbits",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gcimporter",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "gcimporter_test",
+    srcs = [
+        "bexport_test.go",
+        "gcimporter_test.go",
+        "iexport_common_test.go",
+        "iexport_go118_test.go",
+        "iexport_test.go",
+        "israce_test.go",
+        "shallow_test.go",
+        "stdlib_test.go",
+    ],
+    embed = [":gcimporter"],
+    deps = [
+        "//go/gcexportdata",
+        "//go/packages",
+        "//internal/goroot",
+        "//internal/testenv",
+        "@org_golang_x_sync//errgroup:go_default_library",
+    ],
+)
diff -urN b/internal/gcimporter/testdata/a/BUILD.bazel c/internal/gcimporter/testdata/a/BUILD.bazel
--- b/internal/gcimporter/testdata/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/a",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/aliases/a/BUILD.bazel c/internal/gcimporter/testdata/aliases/a/BUILD.bazel
--- b/internal/gcimporter/testdata/aliases/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/aliases/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/aliases/a",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/aliases/b/BUILD.bazel c/internal/gcimporter/testdata/aliases/b/BUILD.bazel
--- b/internal/gcimporter/testdata/aliases/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/aliases/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/aliases/b",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/aliases/c/BUILD.bazel c/internal/gcimporter/testdata/aliases/c/BUILD.bazel
--- b/internal/gcimporter/testdata/aliases/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/aliases/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/aliases/c",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/issue51836/a/BUILD.bazel c/internal/gcimporter/testdata/issue51836/a/BUILD.bazel
--- b/internal/gcimporter/testdata/issue51836/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/issue51836/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/issue51836/a",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/issue51836/BUILD.bazel c/internal/gcimporter/testdata/issue51836/BUILD.bazel
--- b/internal/gcimporter/testdata/issue51836/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/issue51836/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "issue51836",
+    srcs = [
+        "a.go",
+        "aa.go",
+    ],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/issue51836",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/gcimporter/testdata/issue51836/a"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":issue51836",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/issue58296/a/BUILD.bazel c/internal/gcimporter/testdata/issue58296/a/BUILD.bazel
--- b/internal/gcimporter/testdata/issue58296/a/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/issue58296/a/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "a",
+    srcs = ["a.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/issue58296/a",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":a",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/issue58296/b/BUILD.bazel c/internal/gcimporter/testdata/issue58296/b/BUILD.bazel
--- b/internal/gcimporter/testdata/issue58296/b/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/issue58296/b/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "b",
+    srcs = ["b.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/issue58296/b",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":b",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/issue58296/c/BUILD.bazel c/internal/gcimporter/testdata/issue58296/c/BUILD.bazel
--- b/internal/gcimporter/testdata/issue58296/c/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/issue58296/c/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "c",
+    srcs = ["c.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/issue58296/c",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":c",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gcimporter/testdata/versions/BUILD.bazel c/internal/gcimporter/testdata/versions/BUILD.bazel
--- b/internal/gcimporter/testdata/versions/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gcimporter/testdata/versions/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "versions",
+    srcs = ["test.go"],
+    importpath = "golang.org/x/tools/internal/gcimporter/testdata/versions",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":versions",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/gocommand/BUILD.bazel c/internal/gocommand/BUILD.bazel
--- b/internal/gocommand/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gocommand/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,39 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "gocommand",
+    srcs = [
+        "invoke.go",
+        "invoke_notunix.go",
+        "invoke_unix.go",
+        "vendor.go",
+        "version.go",
+    ],
+    importpath = "golang.org/x/tools/internal/gocommand",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event",
+        "//internal/event/keys",
+        "//internal/event/label",
+        "@org_golang_x_mod//semver:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gocommand",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "gocommand_test",
+    srcs = [
+        "invoke_test.go",
+        "version_test.go",
+    ],
+    embed = [":gocommand"],
+    deps = [
+        "//internal/testenv",
+        "@org_golang_x_sync//errgroup:go_default_library",
+    ],
+)
diff -urN b/internal/gopathwalk/BUILD.bazel c/internal/gopathwalk/BUILD.bazel
--- b/internal/gopathwalk/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/gopathwalk/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "gopathwalk",
+    srcs = ["walk.go"],
+    importpath = "golang.org/x/tools/internal/gopathwalk",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":gopathwalk",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "gopathwalk_test",
+    srcs = ["walk_test.go"],
+    embed = [":gopathwalk"],
+)
diff -urN b/internal/goplsexport/BUILD.bazel c/internal/goplsexport/BUILD.bazel
--- b/internal/goplsexport/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/goplsexport/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "goplsexport",
+    srcs = ["export.go"],
+    importpath = "golang.org/x/tools/internal/goplsexport",
+    visibility = ["//:__subpackages__"],
+    deps = ["//go/analysis"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":goplsexport",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/goroot/BUILD.bazel c/internal/goroot/BUILD.bazel
--- b/internal/goroot/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/goroot/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "goroot",
+    srcs = ["importcfg.go"],
+    importpath = "golang.org/x/tools/internal/goroot",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":goroot",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/imports/BUILD.bazel c/internal/imports/BUILD.bazel
--- b/internal/imports/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/imports/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,58 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "imports",
+    srcs = [
+        "fix.go",
+        "imports.go",
+        "mod.go",
+        "mod_cache.go",
+        "sortimports.go",
+        "source.go",
+        "source_env.go",
+        "source_modindex.go",
+    ],
+    importpath = "golang.org/x/tools/internal/imports",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/ast/astutil",
+        "//internal/event",
+        "//internal/gocommand",
+        "//internal/gopathwalk",
+        "//internal/modindex",
+        "//internal/stdlib",
+        "@org_golang_x_mod//module:go_default_library",
+        "@org_golang_x_sync//errgroup:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":imports",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "imports_test",
+    srcs = [
+        "fix_test.go",
+        "imports_test.go",
+        "mod_cache_test.go",
+        "mod_test.go",
+        "sourcex_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    embed = [":imports"],
+    deps = [
+        "//internal/gocommand",
+        "//internal/gopathwalk",
+        "//internal/modindex",
+        "//internal/packagestest",
+        "//internal/proxydir",
+        "//internal/stdlib",
+        "//internal/testenv",
+        "//txtar",
+        "@com_github_google_go_cmp//cmp:go_default_library",
+        "@org_golang_x_mod//module:go_default_library",
+    ],
+)
diff -urN b/internal/jsonrpc2/BUILD.bazel c/internal/jsonrpc2/BUILD.bazel
--- b/internal/jsonrpc2/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/jsonrpc2/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,43 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "jsonrpc2",
+    srcs = [
+        "conn.go",
+        "handler.go",
+        "jsonrpc2.go",
+        "labels.go",
+        "messages.go",
+        "serve.go",
+        "stream.go",
+        "wire.go",
+    ],
+    importpath = "golang.org/x/tools/internal/jsonrpc2",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/event",
+        "//internal/event/keys",
+        "//internal/event/label",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":jsonrpc2",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "jsonrpc2_test",
+    srcs = [
+        "jsonrpc2_test.go",
+        "serve_test.go",
+        "wire_test.go",
+    ],
+    embed = [":jsonrpc2"],
+    deps = [
+        "//internal/event/export/eventtest",
+        "//internal/jsonrpc2/stack/stacktest",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/jsonrpc2/servertest/BUILD.bazel c/internal/jsonrpc2/servertest/BUILD.bazel
--- b/internal/jsonrpc2/servertest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/jsonrpc2/servertest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,22 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "servertest",
+    srcs = ["servertest.go"],
+    importpath = "golang.org/x/tools/internal/jsonrpc2/servertest",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/jsonrpc2"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":servertest",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "servertest_test",
+    srcs = ["servertest_test.go"],
+    embed = [":servertest"],
+    deps = ["//internal/jsonrpc2"],
+)
diff -urN b/internal/jsonrpc2/stack/BUILD.bazel c/internal/jsonrpc2/stack/BUILD.bazel
--- b/internal/jsonrpc2/stack/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/jsonrpc2/stack/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "stack",
+    srcs = [
+        "parse.go",
+        "process.go",
+        "stack.go",
+    ],
+    importpath = "golang.org/x/tools/internal/jsonrpc2/stack",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stack",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "stack_test",
+    srcs = ["stack_test.go"],
+    deps = [":stack"],
+)
diff -urN b/internal/jsonrpc2/stack/stacktest/BUILD.bazel c/internal/jsonrpc2/stack/stacktest/BUILD.bazel
--- b/internal/jsonrpc2/stack/stacktest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/jsonrpc2/stack/stacktest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "stacktest",
+    srcs = ["stacktest.go"],
+    importpath = "golang.org/x/tools/internal/jsonrpc2/stack/stacktest",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/jsonrpc2/stack"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stacktest",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/jsonrpc2_v2/BUILD.bazel c/internal/jsonrpc2_v2/BUILD.bazel
--- b/internal/jsonrpc2_v2/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/jsonrpc2_v2/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,32 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "jsonrpc2_v2",
+    srcs = [
+        "conn.go",
+        "frame.go",
+        "jsonrpc2.go",
+        "messages.go",
+        "net.go",
+        "serve.go",
+        "wire.go",
+    ],
+    importpath = "golang.org/x/tools/internal/jsonrpc2_v2",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":jsonrpc2_v2",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "jsonrpc2_v2_test",
+    srcs = [
+        "jsonrpc2_test.go",
+        "serve_test.go",
+        "wire_test.go",
+    ],
+    deps = [":jsonrpc2_v2"],
+)
diff -urN b/internal/mcp/BUILD.bazel c/internal/mcp/BUILD.bazel
--- b/internal/mcp/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,72 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "mcp",
+    srcs = [
+        "client.go",
+        "cmd.go",
+        "content.go",
+        "features.go",
+        "logging.go",
+        "mcp.go",
+        "prompt.go",
+        "protocol.go",
+        "resource.go",
+        "root.go",
+        "server.go",
+        "shared.go",
+        "sse.go",
+        "streamable.go",
+        "tool.go",
+        "transport.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/internal/mcp",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/jsonrpc2_v2",
+        "//internal/mcp/internal/util",
+        "//internal/mcp/jsonschema",
+        "//internal/xcontext",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":mcp",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "mcp_test",
+    srcs = [
+        "client_list_test.go",
+        "client_test.go",
+        "cmd_test.go",
+        "conformance_go125_test.go",
+        "conformance_test.go",
+        "content_test.go",
+        "example_progress_test.go",
+        "features_test.go",
+        "mcp_test.go",
+        "resource_test.go",
+        "server_example_test.go",
+        "server_test.go",
+        "shared_test.go",
+        "sse_example_test.go",
+        "sse_test.go",
+        "streamable_test.go",
+        "tool_test.go",
+        "transport_test.go",
+        "util_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    embed = [":mcp"],
+    deps = [
+        "//internal/jsonrpc2_v2",
+        "//internal/mcp/jsonschema",
+        "//txtar",
+        "@com_github_google_go_cmp//cmp:go_default_library",
+        "@com_github_google_go_cmp//cmp/cmpopts:go_default_library",
+    ],
+)
diff -urN b/internal/mcp/examples/hello/BUILD.bazel c/internal/mcp/examples/hello/BUILD.bazel
--- b/internal/mcp/examples/hello/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/examples/hello/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "hello_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/internal/mcp/examples/hello",
+    visibility = ["//visibility:private"],
+    deps = ["//internal/mcp"],
+)
+
+go_binary(
+    name = "hello",
+    embed = [":hello_lib"],
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/mcp/examples/sse/BUILD.bazel c/internal/mcp/examples/sse/BUILD.bazel
--- b/internal/mcp/examples/sse/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/examples/sse/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "sse_lib",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/internal/mcp/examples/sse",
+    visibility = ["//visibility:private"],
+    deps = ["//internal/mcp"],
+)
+
+go_binary(
+    name = "sse",
+    embed = [":sse_lib"],
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/mcp/internal/oauthex/BUILD.bazel c/internal/mcp/internal/oauthex/BUILD.bazel
--- b/internal/mcp/internal/oauthex/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/internal/oauthex/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "oauthex",
+    srcs = [
+        "oauth2.go",
+        "resource_meta.go",
+    ],
+    importpath = "golang.org/x/tools/internal/mcp/internal/oauthex",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/mcp/internal/util"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":oauthex",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "oauthex_test",
+    srcs = ["oauth2_test.go"],
+    embed = [":oauthex"],
+)
diff -urN b/internal/mcp/internal/readme/client/BUILD.bazel c/internal/mcp/internal/readme/client/BUILD.bazel
--- b/internal/mcp/internal/readme/client/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/internal/readme/client/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "client_lib",
+    srcs = ["client.go"],
+    importpath = "golang.org/x/tools/internal/mcp/internal/readme/client",
+    visibility = ["//visibility:private"],
+    deps = ["//internal/mcp"],
+)
+
+go_binary(
+    name = "client",
+    embed = [":client_lib"],
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/mcp/internal/readme/server/BUILD.bazel c/internal/mcp/internal/readme/server/BUILD.bazel
--- b/internal/mcp/internal/readme/server/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/internal/readme/server/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "server_lib",
+    srcs = ["server.go"],
+    importpath = "golang.org/x/tools/internal/mcp/internal/readme/server",
+    visibility = ["//visibility:private"],
+    deps = ["//internal/mcp"],
+)
+
+go_binary(
+    name = "server",
+    embed = [":server_lib"],
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/mcp/internal/util/BUILD.bazel c/internal/mcp/internal/util/BUILD.bazel
--- b/internal/mcp/internal/util/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/internal/util/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "util",
+    srcs = ["util.go"],
+    importpath = "golang.org/x/tools/internal/mcp/internal/util",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":util",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "util_test",
+    srcs = ["util_test.go"],
+    embed = [":util"],
+)
diff -urN b/internal/mcp/jsonschema/BUILD.bazel c/internal/mcp/jsonschema/BUILD.bazel
--- b/internal/mcp/jsonschema/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/mcp/jsonschema/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,42 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "jsonschema",
+    srcs = [
+        "annotations.go",
+        "doc.go",
+        "infer.go",
+        "json_pointer.go",
+        "resolve.go",
+        "schema.go",
+        "util.go",
+        "validate.go",
+    ],
+    importpath = "golang.org/x/tools/internal/mcp/jsonschema",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/mcp/internal/util"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":jsonschema",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "jsonschema_test",
+    srcs = [
+        "infer_test.go",
+        "json_pointer_test.go",
+        "resolve_test.go",
+        "schema_test.go",
+        "util_test.go",
+        "validate_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    embed = [":jsonschema"],
+    deps = [
+        "@com_github_google_go_cmp//cmp:go_default_library",
+        "@com_github_google_go_cmp//cmp/cmpopts:go_default_library",
+    ],
+)
diff -urN b/internal/modindex/BUILD.bazel c/internal/modindex/BUILD.bazel
--- b/internal/modindex/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/modindex/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,36 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "modindex",
+    srcs = [
+        "directories.go",
+        "index.go",
+        "lookup.go",
+        "modindex.go",
+        "symbols.go",
+    ],
+    importpath = "golang.org/x/tools/internal/modindex",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/gopathwalk",
+        "@org_golang_x_mod//semver:go_default_library",
+        "@org_golang_x_sync//errgroup:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":modindex",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "modindex_test",
+    srcs = [
+        "dir_test.go",
+        "export_test.go",
+        "lookup_test.go",
+    ],
+    embed = [":modindex"],
+    deps = ["@com_github_google_go_cmp//cmp:go_default_library"],
+)
diff -urN b/internal/modindex/gomodindex/BUILD.bazel c/internal/modindex/gomodindex/BUILD.bazel
--- b/internal/modindex/gomodindex/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/modindex/gomodindex/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")
+
+go_library(
+    name = "gomodindex_lib",
+    srcs = ["cmd.go"],
+    importpath = "golang.org/x/tools/internal/modindex/gomodindex",
+    visibility = ["//visibility:private"],
+    deps = ["//internal/modindex"],
+)
+
+go_binary(
+    name = "gomodindex",
+    embed = [":gomodindex_lib"],
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/moreiters/BUILD.bazel c/internal/moreiters/BUILD.bazel
--- b/internal/moreiters/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/moreiters/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "moreiters",
+    srcs = ["iters.go"],
+    importpath = "golang.org/x/tools/internal/moreiters",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":moreiters",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagesinternal/BUILD.bazel c/internal/packagesinternal/BUILD.bazel
--- b/internal/packagesinternal/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagesinternal/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "packagesinternal",
+    srcs = ["packages.go"],
+    importpath = "golang.org/x/tools/internal/packagesinternal",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":packagesinternal",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/BUILD.bazel c/internal/packagestest/BUILD.bazel
--- b/internal/packagestest/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,40 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "packagestest",
+    srcs = [
+        "expect.go",
+        "export.go",
+        "gopath.go",
+        "modules.go",
+    ],
+    importpath = "golang.org/x/tools/internal/packagestest",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/packages",
+        "//internal/expect",
+        "//internal/gocommand",
+        "//internal/proxydir",
+        "//internal/testenv",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":packagestest",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "packagestest_test",
+    srcs = [
+        "expect_test.go",
+        "export_test.go",
+        "gopath_test.go",
+        "modules_test.go",
+    ],
+    deps = [
+        ":packagestest",
+        "//internal/expect",
+    ],
+)
diff -urN b/internal/packagestest/testdata/BUILD.bazel c/internal/packagestest/testdata/BUILD.bazel
--- b/internal/packagestest/testdata/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,23 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "testdata",
+    srcs = ["test.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":testdata",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "testdata_test",
+    srcs = [
+        "test_test.go",
+        "x_test.go",
+    ],
+    embed = [":testdata"],
+)
diff -urN b/internal/packagestest/testdata/groups/one/modules/example.com/extra/BUILD.bazel c/internal/packagestest/testdata/groups/one/modules/example.com/extra/BUILD.bazel
--- b/internal/packagestest/testdata/groups/one/modules/example.com/extra/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/one/modules/example.com/extra/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "extra",
+    srcs = ["help.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/one/modules/example.com/extra",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":extra",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/one/primarymod/BUILD.bazel c/internal/packagestest/testdata/groups/one/primarymod/BUILD.bazel
--- b/internal/packagestest/testdata/groups/one/primarymod/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/one/primarymod/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "primarymod",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/one/primarymod",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":primarymod",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/modules/example.com/extra/BUILD.bazel c/internal/packagestest/testdata/groups/two/modules/example.com/extra/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/modules/example.com/extra/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/modules/example.com/extra/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "extra",
+    srcs = ["yo.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/modules/example.com/extra",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":extra",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/modules/example.com/extra/geez/BUILD.bazel c/internal/packagestest/testdata/groups/two/modules/example.com/extra/geez/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/modules/example.com/extra/geez/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/modules/example.com/extra/geez/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "geez",
+    srcs = ["help.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/modules/example.com/extra/geez",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":geez",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/BUILD.bazel c/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "extra",
+    srcs = ["me.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":extra",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/geez/BUILD.bazel c/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/geez/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/geez/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/geez/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "geez",
+    srcs = ["help.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/modules/example.com/extra/v2/geez",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":geez",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/modules/example.com/tempmod/BUILD.bazel c/internal/packagestest/testdata/groups/two/modules/example.com/tempmod/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/modules/example.com/tempmod/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/modules/example.com/tempmod/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "tempmod",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/modules/example.com/tempmod",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":tempmod",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.0.0/BUILD.bazel c/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.0.0/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.0.0/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.0.0/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "what@v1_0_0",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.0.0",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":what@v1_0_0",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.1.0/BUILD.bazel c/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.1.0/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.1.0/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.1.0/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "what@v1_1_0",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/modules/example.com/what@v1.1.0",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":what@v1_1_0",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/primarymod/BUILD.bazel c/internal/packagestest/testdata/groups/two/primarymod/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/primarymod/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/primarymod/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "primarymod",
+    srcs = ["main.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/primarymod",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":primarymod",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/packagestest/testdata/groups/two/primarymod/expect/BUILD.bazel c/internal/packagestest/testdata/groups/two/primarymod/expect/BUILD.bazel
--- b/internal/packagestest/testdata/groups/two/primarymod/expect/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/packagestest/testdata/groups/two/primarymod/expect/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,19 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "expect",
+    srcs = ["yo.go"],
+    importpath = "golang.org/x/tools/internal/packagestest/testdata/groups/two/primarymod/expect",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":expect",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "expect_test",
+    srcs = ["yo_test.go"],
+)
diff -urN b/internal/pkgbits/BUILD.bazel c/internal/pkgbits/BUILD.bazel
--- b/internal/pkgbits/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/pkgbits/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,31 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "pkgbits",
+    srcs = [
+        "codes.go",
+        "decoder.go",
+        "doc.go",
+        "encoder.go",
+        "flags.go",
+        "reloc.go",
+        "support.go",
+        "sync.go",
+        "syncmarker_string.go",
+        "version.go",
+    ],
+    importpath = "golang.org/x/tools/internal/pkgbits",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":pkgbits",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "pkgbits_test",
+    srcs = ["pkgbits_test.go"],
+    deps = [":pkgbits"],
+)
diff -urN b/internal/pprof/BUILD.bazel c/internal/pprof/BUILD.bazel
--- b/internal/pprof/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/pprof/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,21 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "pprof",
+    srcs = ["pprof.go"],
+    importpath = "golang.org/x/tools/internal/pprof",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":pprof",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "pprof_test",
+    srcs = ["pprof_test.go"],
+    data = glob(["testdata/**"]),
+    deps = [":pprof"],
+)
diff -urN b/internal/proxydir/BUILD.bazel c/internal/proxydir/BUILD.bazel
--- b/internal/proxydir/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/proxydir/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,20 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "proxydir",
+    srcs = ["proxydir.go"],
+    importpath = "golang.org/x/tools/internal/proxydir",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":proxydir",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "proxydir_test",
+    srcs = ["proxydir_test.go"],
+    embed = [":proxydir"],
+)
diff -urN b/internal/refactor/BUILD.bazel c/internal/refactor/BUILD.bazel
--- b/internal/refactor/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/refactor/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,42 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "refactor",
+    srcs = [
+        "delete.go",
+        "imports.go",
+        "refactor.go",
+    ],
+    importpath = "golang.org/x/tools/internal/refactor",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/analysis",
+        "//go/ast/edge",
+        "//go/ast/inspector",
+        "//internal/analysisinternal",
+        "//internal/astutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":refactor",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "refactor_test",
+    srcs = [
+        "delete_test.go",
+        "imports_test.go",
+    ],
+    deps = [
+        ":refactor",
+        "//go/analysis",
+        "//go/ast/inspector",
+        "//internal/diff",
+        "//internal/testenv",
+        "@com_github_google_go_cmp//cmp:go_default_library",
+    ],
+)
diff -urN b/internal/refactor/inline/BUILD.bazel c/internal/refactor/inline/BUILD.bazel
--- b/internal/refactor/inline/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/refactor/inline/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,55 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "inline",
+    srcs = [
+        "callee.go",
+        "calleefx.go",
+        "doc.go",
+        "escape.go",
+        "falcon.go",
+        "free.go",
+        "inline.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/internal/refactor/inline",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/ast/astutil",
+        "//go/types/typeutil",
+        "//internal/analysisinternal",
+        "//internal/astutil",
+        "//internal/typeparams",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":inline",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "inline_test",
+    srcs = [
+        "calleefx_test.go",
+        "everything_test.go",
+        "export_test.go",
+        "falcon_test.go",
+        "free_test.go",
+        "inline_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    embed = [":inline"],
+    deps = [
+        "//go/ast/astutil",
+        "//go/packages",
+        "//go/types/typeutil",
+        "//internal/diff",
+        "//internal/expect",
+        "//internal/testenv",
+        "//internal/testfiles",
+        "//txtar",
+    ],
+)
diff -urN b/internal/robustio/BUILD.bazel c/internal/robustio/BUILD.bazel
--- b/internal/robustio/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/robustio/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "robustio",
+    srcs = [
+        "gopls_windows.go",
+        "robustio.go",
+        "robustio_darwin.go",
+        "robustio_flaky.go",
+        "robustio_other.go",
+        "robustio_plan9.go",
+        "robustio_posix.go",
+        "robustio_windows.go",
+    ],
+    importpath = "golang.org/x/tools/internal/robustio",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":robustio",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "robustio_test",
+    srcs = ["robustio_test.go"],
+    deps = [":robustio"],
+)
diff -urN b/internal/stdlib/BUILD.bazel c/internal/stdlib/BUILD.bazel
--- b/internal/stdlib/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/stdlib/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,29 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "stdlib",
+    srcs = [
+        "deps.go",
+        "import.go",
+        "manifest.go",
+        "stdlib.go",
+    ],
+    importpath = "golang.org/x/tools/internal/stdlib",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":stdlib",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "stdlib_test",
+    srcs = ["deps_test.go"],
+    data = glob(["testdata/**"]),
+    deps = [
+        ":stdlib",
+        "@com_github_google_go_cmp//cmp:go_default_library",
+    ],
+)
diff -urN b/internal/testenv/BUILD.bazel c/internal/testenv/BUILD.bazel
--- b/internal/testenv/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/testenv/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,23 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "testenv",
+    srcs = [
+        "exec.go",
+        "testenv.go",
+        "testenv_notunix.go",
+        "testenv_unix.go",
+    ],
+    importpath = "golang.org/x/tools/internal/testenv",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//internal/gocommand",
+        "@org_golang_x_mod//modfile:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":testenv",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/testfiles/BUILD.bazel c/internal/testfiles/BUILD.bazel
--- b/internal/testfiles/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/testfiles/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,32 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "testfiles",
+    srcs = ["testfiles.go"],
+    importpath = "golang.org/x/tools/internal/testfiles",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/packages",
+        "//internal/testenv",
+        "//txtar",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":testfiles",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "testfiles_test",
+    srcs = ["testfiles_test.go"],
+    deps = [
+        ":testfiles",
+        "//go/analysis",
+        "//go/analysis/analysistest",
+        "//internal/testenv",
+        "//internal/versions",
+        "//txtar",
+    ],
+)
diff -urN b/internal/testfiles/testdata/versions/BUILD.bazel c/internal/testfiles/testdata/versions/BUILD.bazel
--- b/internal/testfiles/testdata/versions/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/testfiles/testdata/versions/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,18 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "versions",
+    srcs = [
+        "mod.go",
+        "post.go",
+        "pre.go",
+    ],
+    importpath = "golang.org/x/tools/internal/testfiles/testdata/versions",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":versions",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/tool/BUILD.bazel c/internal/tool/BUILD.bazel
--- b/internal/tool/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/tool/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "tool",
+    srcs = ["tool.go"],
+    importpath = "golang.org/x/tools/internal/tool",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":tool",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/typeparams/BUILD.bazel c/internal/typeparams/BUILD.bazel
--- b/internal/typeparams/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/typeparams/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,34 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "typeparams",
+    srcs = [
+        "common.go",
+        "coretype.go",
+        "free.go",
+        "normalize.go",
+        "termlist.go",
+        "typeterm.go",
+    ],
+    importpath = "golang.org/x/tools/internal/typeparams",
+    visibility = ["//:__subpackages__"],
+    deps = ["//internal/aliases"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeparams",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "typeparams_test",
+    srcs = [
+        "common_test.go",
+        "coretype_test.go",
+        "free_test.go",
+        "normalize_test.go",
+    ],
+    embed = [":typeparams"],
+    deps = ["//internal/testenv"],
+)
diff -urN b/internal/typeparams/genericfeatures/BUILD.bazel c/internal/typeparams/genericfeatures/BUILD.bazel
--- b/internal/typeparams/genericfeatures/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/typeparams/genericfeatures/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,15 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "genericfeatures",
+    srcs = ["features.go"],
+    importpath = "golang.org/x/tools/internal/typeparams/genericfeatures",
+    visibility = ["//:__subpackages__"],
+    deps = ["//go/ast/inspector"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":genericfeatures",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/internal/typesinternal/BUILD.bazel c/internal/typesinternal/BUILD.bazel
--- b/internal/typesinternal/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/typesinternal/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,49 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "typesinternal",
+    srcs = [
+        "classify_call.go",
+        "element.go",
+        "errorcode.go",
+        "errorcode_string.go",
+        "fx.go",
+        "isnamed.go",
+        "qualifier.go",
+        "recv.go",
+        "toonew.go",
+        "types.go",
+        "varkind.go",
+        "zerovalue.go",
+    ],
+    importpath = "golang.org/x/tools/internal/typesinternal",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/aliases",
+        "//internal/stdlib",
+        "//internal/versions",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typesinternal",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "typesinternal_test",
+    srcs = [
+        "classify_call_test.go",
+        "element_test.go",
+        "errorcode_test.go",
+        "zerovalue_test.go",
+    ],
+    deps = [
+        ":typesinternal",
+        "//go/types/typeutil",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/typesinternal/typeindex/BUILD.bazel c/internal/typesinternal/typeindex/BUILD.bazel
--- b/internal/typesinternal/typeindex/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/typesinternal/typeindex/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,32 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "typeindex",
+    srcs = ["typeindex.go"],
+    importpath = "golang.org/x/tools/internal/typesinternal/typeindex",
+    visibility = ["//:__subpackages__"],
+    deps = [
+        "//go/ast/edge",
+        "//go/ast/inspector",
+        "//go/types/typeutil",
+        "//internal/typesinternal",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":typeindex",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "typeindex_test",
+    srcs = ["typeindex_test.go"],
+    deps = [
+        ":typeindex",
+        "//go/ast/inspector",
+        "//go/packages",
+        "//go/types/typeutil",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/versions/BUILD.bazel c/internal/versions/BUILD.bazel
--- b/internal/versions/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/versions/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,31 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "versions",
+    srcs = [
+        "features.go",
+        "gover.go",
+        "types.go",
+        "versions.go",
+    ],
+    importpath = "golang.org/x/tools/internal/versions",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":versions",
+    visibility = ["//:__subpackages__"],
+)
+
+go_test(
+    name = "versions_test",
+    srcs = [
+        "types_test.go",
+        "versions_test.go",
+    ],
+    deps = [
+        ":versions",
+        "//internal/testenv",
+    ],
+)
diff -urN b/internal/xcontext/BUILD.bazel c/internal/xcontext/BUILD.bazel
--- b/internal/xcontext/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/internal/xcontext/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "xcontext",
+    srcs = ["xcontext.go"],
+    importpath = "golang.org/x/tools/internal/xcontext",
+    visibility = ["//:__subpackages__"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":xcontext",
+    visibility = ["//:__subpackages__"],
+)
diff -urN b/playground/BUILD.bazel c/playground/BUILD.bazel
--- b/playground/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/playground/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,14 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library")
+
+go_library(
+    name = "playground",
+    srcs = ["playground.go"],
+    importpath = "golang.org/x/tools/playground",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":playground",
+    visibility = ["//visibility:public"],
+)
diff -urN b/playground/socket/BUILD.bazel c/playground/socket/BUILD.bazel
--- b/playground/socket/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/playground/socket/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,24 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "socket",
+    srcs = ["socket.go"],
+    importpath = "golang.org/x/tools/playground/socket",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//txtar",
+        "@org_golang_x_net//websocket:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":socket",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "socket_test",
+    srcs = ["socket_test.go"],
+    embed = [":socket"],
+)
diff -urN b/present/BUILD.bazel c/present/BUILD.bazel
--- b/present/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/present/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,44 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "present",
+    srcs = [
+        "args.go",
+        "caption.go",
+        "code.go",
+        "doc.go",
+        "html.go",
+        "iframe.go",
+        "image.go",
+        "link.go",
+        "parse.go",
+        "style.go",
+        "video.go",
+    ],
+    importpath = "golang.org/x/tools/present",
+    visibility = ["//visibility:public"],
+    deps = [
+        "@com_github_yuin_goldmark//:go_default_library",
+        "@com_github_yuin_goldmark//ast:go_default_library",
+        "@com_github_yuin_goldmark//renderer/html:go_default_library",
+        "@com_github_yuin_goldmark//text:go_default_library",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":present",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "present_test",
+    srcs = [
+        "code_test.go",
+        "link_test.go",
+        "parse_test.go",
+        "style_test.go",
+    ],
+    data = glob(["testdata/**"]),
+    embed = [":present"],
+)
diff -urN b/refactor/eg/BUILD.bazel c/refactor/eg/BUILD.bazel
--- b/refactor/eg/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/refactor/eg/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,132 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "eg",
+    srcs = [
+        "eg.go",
+        "match.go",
+        "rewrite.go",
+    ],
+    importpath = "golang.org/x/tools/refactor/eg",
+    visibility = ["//visibility:public"],
+    deps = ["//go/ast/astutil"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":eg",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "eg_test",
+    srcs = ["eg_test.go"],
+    data = glob(["testdata/**"]),
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            ":eg",
+            "//go/packages",
+            "//internal/testenv",
+            "//internal/testfiles",
+            "//txtar",
+            "@com_github_google_go_cmp//cmp:go_default_library",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/refactor/importgraph/BUILD.bazel c/refactor/importgraph/BUILD.bazel
--- b/refactor/importgraph/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/refactor/importgraph/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,75 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "importgraph",
+    srcs = ["graph.go"],
+    importpath = "golang.org/x/tools/refactor/importgraph",
+    visibility = ["//visibility:public"],
+    deps = ["//go/buildutil"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":importgraph",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "importgraph_test",
+    srcs = ["graph_test.go"],
+    deps = select({
+        "@io_bazel_rules_go//go/platform:aix": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:darwin": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:dragonfly": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:freebsd": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:illumos": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:ios": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:js": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:linux": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:netbsd": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:openbsd": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:plan9": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:solaris": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "@io_bazel_rules_go//go/platform:windows": [
+            ":importgraph",
+            "//internal/packagestest",
+        ],
+        "//conditions:default": [],
+    }),
+)
diff -urN b/refactor/rename/BUILD.bazel c/refactor/rename/BUILD.bazel
--- b/refactor/rename/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/refactor/rename/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,44 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "rename",
+    srcs = [
+        "check.go",
+        "mvpkg.go",
+        "rename.go",
+        "spec.go",
+        "util.go",
+    ],
+    importpath = "golang.org/x/tools/refactor/rename",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/buildutil",
+        "//go/loader",
+        "//go/types/typeutil",
+        "//internal/astutil",
+        "//internal/typeparams",
+        "//internal/typesinternal",
+        "//refactor/importgraph",
+        "//refactor/satisfy",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":rename",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "rename_test",
+    srcs = [
+        "mvpkg_test.go",
+        "rename_test.go",
+    ],
+    embed = [":rename"],
+    deps = [
+        "//go/buildutil",
+        "//internal/aliases",
+        "//internal/testenv",
+    ],
+)
diff -urN b/refactor/satisfy/BUILD.bazel c/refactor/satisfy/BUILD.bazel
--- b/refactor/satisfy/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/refactor/satisfy/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,27 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "satisfy",
+    srcs = ["find.go"],
+    importpath = "golang.org/x/tools/refactor/satisfy",
+    visibility = ["//visibility:public"],
+    deps = [
+        "//go/types/typeutil",
+        "//internal/typeparams",
+    ],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":satisfy",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "satisfy_test",
+    srcs = ["find_test.go"],
+    deps = [
+        ":satisfy",
+        "//internal/testenv",
+    ],
+)
diff -urN b/txtar/BUILD.bazel c/txtar/BUILD.bazel
--- b/txtar/BUILD.bazel	1969-12-31 18:00:00.000000000 -0600
+++ c/txtar/BUILD.bazel	2000-01-01 00:00:00.000000000 -0000
@@ -0,0 +1,26 @@
+load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
+
+go_library(
+    name = "txtar",
+    srcs = [
+        "archive.go",
+        "fs.go",
+    ],
+    importpath = "golang.org/x/tools/txtar",
+    visibility = ["//visibility:public"],
+)
+
+alias(
+    name = "go_default_library",
+    actual = ":txtar",
+    visibility = ["//visibility:public"],
+)
+
+go_test(
+    name = "txtar_test",
+    srcs = [
+        "archive_test.go",
+        "fs_test.go",
+    ],
+    embed = [":txtar"],
+)
