[patch] [libcxx] new/.cpp trivial warning fix.
gmisocpp at gmail.com
Thu Oct 24 19:13:34 PDT 2013
I don't understand this code:
_LIBCPP_NEW_DELETE_VIS void* operator new(std::size_t __sz)
Are you anticipating that operator new will throw things other than
Or does MSVC just hate exception specifications?
[ I'm not really that fond of them, but still …. ]
Yes I thought the code was a bit weird to begin with too. I'm just adding
more of the same. But I think the logic is something like, "exception
specifications are deprecated/going away, if the compiler is aware that we
don't need them, don't use them. If the compiler isn't aware that we don't
need them, use what we know works. for clang that's throw x; meaning we
throw x; for msvc that's throw(...) meaning say we throw something, but I
don't know what and don't support a meaning of saying what.".
It's the only place this type of thing is used, so there isn't any
value supporting some kind of clever macro for that. The whole ugliness
will go away for all compilers soon enough I think.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the cfe-commits