<div dir="ltr">Please see <a href="http://reviews.llvm.org/D7707">http://reviews.llvm.org/D7707</a>.<div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Feb 17, 2015 at 7:22 AM, Marshall Clow <span dir="ltr"><<a href="mailto:mclow.lists@gmail.com" target="_blank">mclow.lists@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><span class=""><div><blockquote type="cite"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><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><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><div><div>These new declarations should be wrapped in a version check; we should only declare them in <new> if we're in C++14 or later.</div></div></div></div></div></div></blockquote><div><br></div></div></div><div>Clang also supports the -fsized-deallocation flag in C++11 mode. Should we factor this in the version check as well, or perhaps</div><div>remove/deprecate it from Clang?</div></div></div></div></blockquote><div><br></div><div>I don't think there's any need to care about whether the feature is enabled in Clang. The non-nothrow forms are implicitly declared by the compiler, so libc++'s declarations are redundant in all modes (but technically the standard says they should be there in <new> in C++14, so I suppose we should include them for completeness). The nothrow forms are useless and never implicitly called, but we're (currently; I have filed a library issue) required to provide them.</div><div><br></div><div>So I think you should just check whether libc++ is in C++14 mode, and declare these functions if so.</div></div></div></div></blockquote><br></div></span><div>There’s a whole set of deployment issues that we need to deal with here; none of which apply to people who build libc++ for their own use.</div><div><br></div><div>Here’s a couple, using Mac OS as an example - but the same thing applies to FreeBSD (and others).</div><div><br></div><div>1) Apple ships an update to Xcode that contains the changes to <new>, but not an updated dylib (because the dev tools and system libraries are shipped in different vehicles). Does this mean that you can build an app that will not run because the dylib is missing calls?</div><div><br></div><div>2) Apple ships (say) 10.11.0 with an updated dylib. A developer builds and tests his app with this, and puts it on the app store. A user purchases the app, only to find that it doesn’t run on his (10.10) system.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>— Marshall</div><div><br></div></font></span></div><br>_______________________________________________<br>
cfe-commits mailing list<br>
<a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a><br>
<br></blockquote></div><br></div>