<div dir="ltr">That sounds good. After all, when creating a precompiled header file, you don't even want an object file at that time anyway, and if the precompiled header fails to build, you expect to have to stop and fix it before you can usefully do anything else.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 11, 2015 at 7:35 PM, Nico Weber via cfe-dev <span dir="ltr"><<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><div class="h5">On Fri, Dec 11, 2015 at 1:42 PM, Reid Kleckner via cfe-dev <span dir="ltr"><<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span>On Fri, Dec 11, 2015 at 10:26 AM, Richard Smith via cfe-dev <span dir="ltr"><<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><p dir="ltr"><span style="color:rgb(34,34,34)">-Xclang passes only the immediately following argument to cc1. You need</span><br></p></div></div>
<p dir="ltr">clang-cl -fms-compatibility-version=19 -Xclang -include-pch -Xclang a.h.gch a.cpp</p>
<p dir="ltr">Also, the -Xclang / -cc1 interface is not really supported and has no stability guarantees; do the cl.exe flags for PCH not work in clang-cl? (If not, please file a bug on that.)</p></blockquote></span><div>Nico was going to take a shot at making the /Y preprocessor flags work with clang-cl, but I don't think he got around to it. I think it's not as easy as adding more aliases, you have to add some driver logic. <br></div></div></div></div></blockquote><div><br></div></div></div><div>I actually have a pretty complete patch that seems to work modulo testing and error handling (the most significant problem is that if your precompiled header fails to build, the driver currently still goes ahead and tries to use the (non-existent) gch file to produce the .obj file in /Yc mode).</div><span class=""><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div></div></div></div></div>
<br>_______________________________________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a><br>
<br></blockquote></span></div><br></div></div>
<br>_______________________________________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div><br></div>