Skip to content

Commit c85f8b7

Browse files
committed
Add comments explaining regex capture groups in lit.cfg
1 parent dc879cc commit c85f8b7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

test/lit.cfg

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2938,6 +2938,9 @@ config.substitutions.append(('%target-run-stdlib-swift', config.target_run_stdli
29382938
config.substitutions.append(('%target-repl-run-simple-swift', subst_target_repl_run_simple_swift))
29392939
config.substitutions.append(('%target-run', config.target_run))
29402940
config.substitutions.append(('%target-jit-run', subst_target_jit_run))
2941+
# Capture groups:
2942+
# \1 = path before the file name (non-greedy)
2943+
# \2 = file name (last component, no slashes or parentheses)
29412944
config.substitutions.append(('%target-build-swift-dylib\(([^)]+?)([^/\\()]+)\)', config.target_build_swift_dylib))
29422945
config.substitutions.append(('%target-codesign', config.target_codesign))
29432946
config.substitutions.append(('%target-build-swift', config.target_build_swift))

0 commit comments

Comments
 (0)