[cfe-dev] what libc++ version introduced C++14 delete operators?
René J. V. Bertin via cfe-dev
cfe-dev at lists.llvm.org
Tue Dec 5 02:28:10 PST 2017
Marshall Clow via cfe-dev wrote:
Hi,
> An imperfect test would be checking _LIBCPP_VERSION and if it is greater
> than 1101, then it will have those calls.
Thanks, that's better than nothing.
> This has two drawbacks:
> * There will be versions of libc++ where _LIBCPP_VERSION == 1101 and the
> calls exist.
The application here is a GCC patch I'm working on (and off :)) to give it a -
stdlib=libstdc++|libc++ option. With older libc++ versions it appears to be
possible to use GCC's static libsupc++ as a source for the missing operators. I
presume that a trailing -lsupc++ linker argument will simply become a noop when
libc++ already provided all dependencies. To be confirmed of course (and sadly I
have no idea ATM how to write a test case.)
> * There *may* be customized versions of libc++ where vendors have decided
> to not ship those calls. (I don't know of any, but ...).
Why would vendors have done that? The only reason I can see is to allow a newer
libc++ to be used with older clang versions that provided the operators
implicitly, but such combinations shouldn't cause problems anyway, right?
R.
More information about the cfe-dev
mailing list