From 7a8ff500d3a77ef8d70c25fd26a57c673ac324aa Mon Sep 17 00:00:00 2001 From: Son Luong Ngoc Date: Tue, 28 Jun 2022 21:40:48 +0200 Subject: [PATCH] new_library: remove unused resolver `_testmain_library_to_source` was introduced in 1c4f6fd1 and last usage of this resolver was in 56e5592c. ``` > git log -S'_testmain_library_to_source' --oneline 56e5592c Move the test library rule to be go_test internal actions (#1267) 9031d58e Add GoContext (#1140) 1c4f6fd1 Fix aspect based proto builds (#1131) ``` Let's remove the unused resolver and replace the documentation with the resolver that is actually being used. --- go/private/rules/test.bzl | 3 --- go/toolchains.rst | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/go/private/rules/test.bzl b/go/private/rules/test.bzl index fb1d413cc9..1dfd155561 100644 --- a/go/private/rules/test.bzl +++ b/go/private/rules/test.bzl @@ -54,9 +54,6 @@ load( "structs", ) -def _testmain_library_to_source(go, attr, source, merge): - source["deps"] = source["deps"] + [attr.library] - def _go_test_impl(ctx): """go_test_impl implements go testing. diff --git a/go/toolchains.rst b/go/toolchains.rst index f394ff07ce..2358249bcb 100644 --- a/go/toolchains.rst +++ b/go/toolchains.rst @@ -940,7 +940,7 @@ resolver when it is invoked. | | | .. code:: bzl | | | -| def _testmain_library_to_source(go, attr, source, merge) | +| def _stdlib_library_to_source(go, attr, source, merge) | | | | attr is the attributes of the rule being processed | | source is the dictionary of GoSource fields being generated |