Changing this without other further patch might cause clangd results in Runtime Error while handling files like CUDA.
This part is not used by clangd. However it is used together with PrecompiledPreamble, so maybe all three need to be changed together.
(Just trying to understand whether this is part of the minimal change, but I think you have this right)
This looks like a good, correct change, but I think it should be in a separate patch.
I suspect -Xclang -chained-include is just really rare in practice.
What kind of runtime error can this result in and why? What's the current behavior?
My guess is if this has to be consistent between preamble + main AST, then you should change PrecompiledPreamble, ASTUnit, and clangd together in one patch and leave others.
Since, originally, I think it is OK to submit patch just by project, but I agree that it's better to make patch as minimal as possible.
Thus, I will abandon this and resubmit another patch.
(I think reuploading patch and changing the whole patch logic here might not be great?)
Yes, this is because the inconsistency between preamble and main AST. I will reorder my patch.