Skip to content

Commit 27b65a8

Browse files
Nikita Patskovfacebook-github-bot
Nikita Patskov
authored andcommitted
Separated other outputs to a variable
Summary: Just a convenience refactoring Differential Revision: D73427255 fbshipit-source-id: 6bb09ae02b70170100a20f480fc47b5f1f574e25
1 parent 8547d47 commit 27b65a8

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

cxx/cxx_executable.bzl

+7-5
Original file line numberDiff line numberDiff line change
@@ -758,14 +758,16 @@ def cxx_executable(ctx: AnalysisContext, impl_params: CxxRuleConstructorParams,
758758

759759
if binary.dwp:
760760
# A `dwp` sub-target which generates the `.dwp` file for this binary and its shared lib dependencies.
761+
shared_libraries_dwp = [
762+
shlib.lib.dwp
763+
for shlib in shared_libs
764+
if shlib.lib.dwp
765+
] + ([link_result.dwp_symlink_tree] if link_result.dwp_symlink_tree else [])
766+
761767
sub_targets["dwp"] = [
762768
DefaultInfo(
763769
default_output = binary.dwp,
764-
other_outputs = [
765-
shlib.lib.dwp
766-
for shlib in shared_libs
767-
if shlib.lib.dwp
768-
] + ([link_result.dwp_symlink_tree] if link_result.dwp_symlink_tree else []),
770+
other_outputs = shared_libraries_dwp,
769771
),
770772
]
771773

0 commit comments

Comments
 (0)