perf: remove unnecessary calls to 'to_list' (#737)
This commit is contained in:
parent
f0a19f5a7c
commit
59cc7058de
|
@ -57,7 +57,7 @@ CopyToDirectoryInfo = provider(
|
||||||
)
|
)
|
||||||
|
|
||||||
def _copy_directory_toolchain_impl(ctx):
|
def _copy_directory_toolchain_impl(ctx):
|
||||||
binary = ctx.attr.bin.files.to_list()[0]
|
binary = ctx.file.bin
|
||||||
|
|
||||||
default_info = DefaultInfo(
|
default_info = DefaultInfo(
|
||||||
files = depset([binary]),
|
files = depset([binary]),
|
||||||
|
|
|
@ -57,7 +57,7 @@ CopyToDirectoryInfo = provider(
|
||||||
)
|
)
|
||||||
|
|
||||||
def _copy_to_directory_toolchain_impl(ctx):
|
def _copy_to_directory_toolchain_impl(ctx):
|
||||||
binary = ctx.attr.bin.files.to_list()[0]
|
binary = ctx.file.bin
|
||||||
|
|
||||||
default_info = DefaultInfo(
|
default_info = DefaultInfo(
|
||||||
files = depset([binary]),
|
files = depset([binary]),
|
||||||
|
|
|
@ -65,7 +65,7 @@ JqInfo = provider(
|
||||||
)
|
)
|
||||||
|
|
||||||
def _jq_toolchain_impl(ctx):
|
def _jq_toolchain_impl(ctx):
|
||||||
binary = ctx.attr.bin.files.to_list()[0]
|
binary = ctx.file.bin
|
||||||
|
|
||||||
# Make the $(JQ_BIN) variable available in places like genrules.
|
# Make the $(JQ_BIN) variable available in places like genrules.
|
||||||
# See https://docs.bazel.build/versions/main/be/make-variables.html#custom_variables
|
# See https://docs.bazel.build/versions/main/be/make-variables.html#custom_variables
|
||||||
|
|
|
@ -314,7 +314,7 @@ YqInfo = provider(
|
||||||
)
|
)
|
||||||
|
|
||||||
def _yq_toolchain_impl(ctx):
|
def _yq_toolchain_impl(ctx):
|
||||||
binary = ctx.attr.bin.files.to_list()[0]
|
binary = ctx.file.bin
|
||||||
|
|
||||||
# Make the $(YQ_BIN) variable available in places like genrules.
|
# Make the $(YQ_BIN) variable available in places like genrules.
|
||||||
# See https://docs.bazel.build/versions/main/be/make-variables.html#custom_variables
|
# See https://docs.bazel.build/versions/main/be/make-variables.html#custom_variables
|
||||||
|
|
Loading…
Reference in New Issue