C++: Add getSkylarkArgv to CppLinkAction
RELNOTES:none
@@ -53,6 +53,7 @@ import com.google.devtools.build.lib.cmdline.RepositoryName;
import com.google.devtools.build.lib.collect.CollectionUtils;
import com.google.devtools.build.lib.collect.nestedset.NestedSet;
import com.google.devtools.build.lib.concurrent.ThreadSafety.ThreadCompatible;
+import com.google.devtools.build.lib.events.Location;
import com.google.devtools.build.lib.rules.cpp.Link.LinkingMode;
import com.google.devtools.build.lib.rules.cpp.LinkerInputs.LibraryToLink;
import com.google.devtools.build.lib.skyframe.serialization.autocodec.AutoCodec;
@@ -573,4 +574,13 @@ public final class CppLinkAction extends AbstractAction implements CommandAction
}
}
}
+
+ @Override
+ public Sequence<String> getSkylarkArgv() throws EvalException {
+ try {
+ return StarlarkList.immutableCopyOf(getArguments());
+ } catch (CommandLineExpansionException exception) {
+ throw new EvalException(Location.BUILTIN, exception);
+ }
+ }
}
