Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove orig_src_map #4025

Merged
merged 1 commit into from
Aug 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion go/private/actions/archive.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,6 @@ def emit_archive(go, source = None, _recompile_suffix = "", recompile_internal_d
# GoSource fields
srcs = as_tuple(source.srcs),
orig_srcs = as_tuple(source.orig_srcs),
_orig_src_map = tuple([source.orig_src_map.get(src, src) for src in source.srcs]),
_cover = as_tuple(source.cover),
_embedsrcs = as_tuple(source.embedsrcs),
_x_defs = tuple(source.x_defs.items()),
Expand Down
2 changes: 0 additions & 2 deletions go/private/context.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ def _merge_embed(source, embed):
s = get_source(embed)
source["srcs"] = s.srcs + source["srcs"]
source["orig_srcs"] = s.orig_srcs + source["orig_srcs"]
source["orig_src_map"].update(s.orig_src_map)
source["embedsrcs"] = source["embedsrcs"] + s.embedsrcs
source["cover"] = source["cover"] + s.cover
source["deps"] = source["deps"] + s.deps
Expand Down Expand Up @@ -277,7 +276,6 @@ def _library_to_source(go, attr, library, coverage_instrumented):
"mode": go.mode,
"srcs": srcs,
"orig_srcs": srcs,
"orig_src_map": {},
"cover": [],
"embedsrcs": embedsrcs,
"x_defs": {},
Expand Down
1 change: 0 additions & 1 deletion go/private/rules/test.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -674,7 +674,6 @@ def _recompile_external_deps(go, external_source, internal_archive, library_labe
mode = go.mode,
srcs = as_list(arc_data.srcs),
orig_srcs = as_list(arc_data.orig_srcs),
orig_src_map = dict(zip(arc_data.srcs, arc_data._orig_src_map)),
cover = arc_data._cover,
embedsrcs = as_list(arc_data._embedsrcs),
x_defs = dict(arc_data._x_defs),
Expand Down
5 changes: 0 additions & 5 deletions go/providers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -134,11 +134,6 @@ method. In general, only rules_go should need to build or handle these.
| The original source files this library is based on. This may differ from |
| :param:`srcs` if processing tools such as cgo or cover are applied. |
+--------------------------------+-----------------------------------------------------------------+
| :param:`orig_src_map` | :type:`dict of File to File` |
+--------------------------------+-----------------------------------------------------------------+
| Maps generated files in :param:`srcs` back to :param:`orig_srcs`. Not all |
| generated files may appear in here. |
+--------------------------------+-----------------------------------------------------------------+
| :param:`embedsrcs` | :type:`list of File` |
+--------------------------------+-----------------------------------------------------------------+
| Files that may be embedded into the compiled package using ``//go:embed`` |
Expand Down