Not passing --clang would result in a python exception after this change:
(TypeError: expected str, bytes or os.PathLike object, not NoneType)
because the --clang argument default was only being populated in the
initial argument parsing pass but not later on.
Fix this by adding an argparse callback to set the default values.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/test/utils/update_cc_test_checks/lit.local.cfg | ||
---|---|---|
24 ↗ | (On Diff #280399) | The substitution is here just to make a test. Can it be tested with existing substitutions? |
clang/test/utils/update_cc_test_checks/lit.local.cfg | ||
---|---|---|
24 ↗ | (On Diff #280399) | I can't think of an easy way since we need to invoke update_cc_test_checks.py without the "--clang" argument and we need a substitution for the path to the update script. |
Comment Actions
LGTM as it fixes update_cc_test_checks.py
llvm/utils/update_cc_test_checks.py | ||
---|---|---|
116–126 | I guess empty clang also make no sense, "not args.clang" is better here |
clang/test/utils/update_cc_test_checks/lit.local.cfg | ||
---|---|---|
24 ↗ | (On Diff #280399) | If there are concerns here, I'd recommend to land minimal fix for the tool and move test plumbing into a separate patch. |
Comment Actions
LGTM.
clang/test/utils/update_cc_test_checks/lit.local.cfg | ||
---|---|---|
24 ↗ | (On Diff #280399) |
+1 |
I guess empty clang also make no sense, "not args.clang" is better here