This patch uses a different command-line arguments to test clang::tooling::ToolInvocation that are not specific to Darwin.
Details
Diff Detail
- Repository
 - rG LLVM Github Monorepo
 
Event Timeline
| clang/unittests/Tooling/ToolingTest.cpp | ||
|---|---|---|
| 238–244 | I'm worried this is going to behave differently when the unit test isn't run on Darwin, since I think -isysroot is only valid for Darwin targets and there's no -arch or -target option. Can you confirm whether this should reproduce properly when run on other hosts as well?  | |
Stepping back, maybe it'd be better to use a more generic option that is unlikely to have special behaviour in any target (or downstream).
Best one I could find is triggering err_drv_unknown_language with -x this-is-an-unknown-language. WDYT?
| clang/unittests/Tooling/ToolingTest.cpp | ||
|---|---|---|
| 277–280 | Can this just be empty and use -E? But if you switch to another error maybe you don't need to modify this anyway?  | |
I'm worried this is going to behave differently when the unit test isn't run on Darwin, since I think -isysroot is only valid for Darwin targets and there's no -arch or -target option. Can you confirm whether this should reproduce properly when run on other hosts as well?