This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH. libstdc++] Use the correct C++14 __cplusplus value (201402L). Added C++1z to the preprocessor.
- From: Jonathan Wakely <jwakely at redhat dot com>
- To: Paolo Carlini <paolo dot carlini at oracle dot com>
- Cc: Ed Smith-Rowland <3dw4rd at verizon dot net>, "libstdc++ at gcc dot gnu dot org" <libstdc++ at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 26 Aug 2014 09:52:06 +0100
- Subject: Re: [PATCH. libstdc++] Use the correct C++14 __cplusplus value (201402L). Added C++1z to the preprocessor.
- Authentication-results: sourceware.org; auth=none
- References: <53F91799 dot 2070902 at verizon dot net> <53FC4524 dot 9090606 at oracle dot com>
On 26/08/14 10:28 +0200, Paolo Carlini wrote:
On 08/24/2014 12:37 AM, Ed Smith-Rowland wrote:
With revision 214400 we have the C++14 value of __cplusplus set to
the correct value of 201402L (from 201300L).
It occurs to me: instead of having to remember every time those
numbers, couldn't we predefine, for example:
with the correct values of course?!?
That seems like a good idea, but I'm not convinced there's any benefit
in Ed's changes to do:
-#if __cplusplus > 201103L
+#if __cplusplus >= 201402L
It seems like unnecessary churn to me, but if someone was changing
every test to use a symbolic constant instead of an integer literal
then I suppose it does no harm to change "> C++11" to ">= C++14" at
the same time.