Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-14 Thread Rainer Orth
Jason Merrill ja...@redhat.com writes: While I was going over the C++11 status page, I noticed that quick_exit is implemented by glibc, it just needed to be added to the libstdc++ cstdlib header. The test fails on Solaris 9: FAIL: 18_support/quick_exit/quick_exit.cc (test for excess errors)

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-14 Thread Paolo Carlini
Hi Rainer, On 02/14/2013 04:45 PM, Rainer Orth wrote: Jason Merrill ja...@redhat.com writes: While I was going over the C++11 status page, I noticed that quick_exit is implemented by glibc, it just needed to be added to the libstdc++ cstdlib header. The test fails on Solaris 9: FAIL:

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-14 Thread Paolo Carlini
... or the below, just in case an interesting system provides the *quick_exit functions but doesn't define _GLIBCXX_USE_C99. Paolo. /// Index: testsuite/18_support/quick_exit/quick_exit.cc === ---

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-14 Thread Jason Merrill
On 02/14/2013 02:16 PM, Paolo Carlini wrote: ... or the below, just in case an interesting system provides the *quick_exit functions but doesn't define _GLIBCXX_USE_C99. It seems rather unlikely that the system would provide some C11 functions without the corresponding C99 ones. I'm just

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-13 Thread Jason Merrill
On 02/12/2013 07:55 AM, Paolo Carlini wrote: Again, the current status is in a sense good because when the _GLIBCXX_HAVE_AT_QUICK_EXIT and _GLIBCXX_HAVE_QUICK_EXIT are defined, thus the system has the functions in its c library, including cstdlib makes available the functions in namespace std

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-13 Thread Paolo Carlini
Hi, On 02/13/2013 03:38 PM, Jason Merrill wrote: On 02/12/2013 07:55 AM, Paolo Carlini wrote: Again, the current status is in a sense good because when the _GLIBCXX_HAVE_AT_QUICK_EXIT and _GLIBCXX_HAVE_QUICK_EXIT are defined, thus the system has the functions in its c library, including

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-12 Thread Dominique Dhumieres
The test fails on x86_64-apple-darwin10 with FAIL: 18_support/quick_exit/quick_exit.cc (test for excess errors) Excess errors: /opt/gcc/work/libstdc++-v3/testsuite/18_support/quick_exit/quick_exit.cc:36:3: error: 'at_quick_exit' is not a member of 'std'

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-12 Thread Paolo Carlini
On 02/12/2013 12:26 PM, domi...@lps.ens.fr wrote: The test fails on x86_64-apple-darwin10 with FAIL: 18_support/quick_exit/quick_exit.cc (test for excess errors) Excess errors: /opt/gcc/work/libstdc++-v3/testsuite/18_support/quick_exit/quick_exit.cc:36:3: error: 'at_quick_exit' is not a member

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-12 Thread Paolo Carlini
On 02/12/2013 12:32 PM, Paolo Carlini wrote: On 02/12/2013 12:26 PM, domi...@lps.ens.fr wrote: The test fails on x86_64-apple-darwin10 with FAIL: 18_support/quick_exit/quick_exit.cc (test for excess errors) Excess errors:

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-12 Thread Dominique Dhumieres
IIRC I have already asked a similar question about atan2, erf, ... which don't appear in the std namespace on darwin. Dominique

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-12 Thread Paolo Carlini
On 02/12/2013 12:40 PM, domi...@lps.ens.fr wrote: IIRC I have already asked a similar question about atan2, erf, ... which don't appear in the std namespace on darwin. You should check whether darwin by chance uses by default c_std instead of c_global. The former doesn't provide C++11

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-12 Thread Dominique Dhumieres
But the last time I checked, modern darwin defined _GLIBCXX_USE_C99_MATH_TR1, no problems. AFAICT this is true, but I think darwin10 was released in 2011 so I doubt it has any support for c++11. Anyway, about the cstdlib issue the below makes available the new functions in c_std/cstdlib

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-12 Thread Paolo Carlini
On 02/12/2013 01:47 PM, domi...@lps.ens.fr wrote: But the last time I checked, modern darwin defined _GLIBCXX_USE_C99_MATH_TR1, no problems. AFAICT this is true, but I think darwin10 was released in 2011 so I doubt it has any support for c++11. Anyway, about the cstdlib issue the below makes

RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-11 Thread Jason Merrill
While I was going over the C++11 status page, I noticed that quick_exit is implemented by glibc, it just needed to be added to the libstdc++ cstdlib header. Does this configury/feature macro handling look right? Is this enough testcase? Is this small/safe enough to go in for 4.8? commit

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-11 Thread Benjamin De Kosnik
Does this configury/feature macro handling look right? yes. Is this enough testcase? yes. Is this small/safe enough to go in for 4.8? yes. commit 884a2a7815a95bade9d23f01b4c64a16808c7f05 Author: Jason Merrill ja...@redhat.com Date: Mon Feb 11 11:23:30 2013 -0500 *

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-11 Thread Paolo Carlini
Hi, On 02/11/2013 06:33 PM, Jason Merrill wrote: While I was going over the C++11 status page, I noticed that quick_exit is implemented by glibc, it just needed to be added to the libstdc++ cstdlib header. Does this configury/feature macro handling look right? Is this enough testcase? Is

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-11 Thread Paolo Carlini
.. also, I think we should have #if __cplusplus = 201103L protecting these functions too, exactly like all the other C++11 bits. Eg, I don't think we should unconditionally, ie in C++03 mode too, declare at_quick_exit and quick_exit in namespace std. I can tweak things for the two issues I

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-11 Thread Benjamin De Kosnik
.. also, I think we should have #if __cplusplus = 201103L protecting these functions too, exactly like all the other C++11 bits. Eg, I don't think we should unconditionally, ie in C++03 mode too, declare at_quick_exit and quick_exit in namespace std. Yeah. I can tweak things for the two

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-11 Thread Paolo Carlini
On 02/11/2013 07:54 PM, Benjamin De Kosnik wrote: I can tweak things for the two issues I noticed. Thanks. It seems like this is still 4.8 material to me. Great. I'll take care of that later today. I'm also going to make sure the new testcase doesn't spuriously fail if the functions aren't

Re: RFA: v3 PATCH to add on_quick_exit/quick_exit to std

2013-02-11 Thread Paolo Carlini
... this is what I committed. Thanks, Paolo. / 2013-02-11 Paolo Carlini paolo.carl...@oracle.com * include/c_std/cstdlib (at_quick_exit, quick_exit): Do not declare. * include/c_global/cstdlib (at_quick_exit, quick_exit): Declare only in C++11 mode