Skip to content

Commit 3de0af9

Browse files
committed
split-cmdline: the -c option only has an argument for swiftpm, but not for the compiler
1 parent 45d15d1 commit 3de0af9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

utils/dev-scripts/split-cmdline

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ def main():
9191
# ) | rg -o -r '$3 $2' -- ' ((-[\w-]+),)? (-[\w-]+) <' \
9292
# | sed 's/ *$//' | tr ' ' '\n' \
9393
# | sort | uniq \
94+
# | grep -v -e '-c$' \
9495
# | sed -E 's/(.*)/"\1",/'
9596
"--analyzer-output",
9697
"--build-system",
@@ -160,7 +161,6 @@ def main():
160161
"-batch-scan-input-file",
161162
"-blocklist-file",
162163
"-build-id",
163-
"-c",
164164
"-cache-replay-prefix-map",
165165
"-cas-path",
166166
"-cas-plugin-option",
@@ -340,6 +340,8 @@ def main():
340340
# Heuristic: options ending in -path expect an argument
341341
if arg.startswith("-") and arg.endswith("-path"):
342342
is_arg_param = True
343+
if arg == "-c" and args[0] == "swift":
344+
is_arg_param = True
343345

344346
# Print 2 new lines after each command line
345347
print("\n")

0 commit comments

Comments
 (0)