================
@@ -4402,8 +4403,12 @@ clang_parseTranslationUnit_Impl(CXIndex CIdx, const char 
*source_filename,
   Args->insert(Args->end(), command_line_args,
                command_line_args + num_command_line_args);
 
+  // Use the driver pass-through spelling for options not accepted by clang-cl.
+  bool IsCLMode = driver::IsClangCL(
----------------
AaronBallman wrote:

My primary concern here is that we shouldn't have to look at the driver mode at 
all (that makes it harder for us to add new driver modes in the future because 
we have to remember to come fix these places up too). Would it work to pass 
`-Xclang` and the CC1 argument directly? e.g.,
```
    Args->push_back("-Xclang");
    Args->push_back("-fno-spell-checking");
```
or can we find a driver-agnostic way to do this?

https://github.com/llvm/llvm-project/pull/237563
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to