Topic: latest c++0x draft and exception specifications.


Author: german diago <germandiago@gmail.com>
Date: Wed, 7 Apr 2010 11:38:42 CST
Raw View
  Looking at the latest c++0x draft, I saw that numeric_limits
functions have throw() specifiers, which have been deprecated. Are
this being changed by noexcept specifiers? Maybe they're changing it
for the next draft? Thanks.

--
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use
mailto:std-c++@netlab.cs.rpi.edu<std-c%2B%2B@netlab.cs.rpi.edu>
]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]





Author: =?ISO-8859-1?Q?Daniel_Kr=FCgler?= <daniel.kruegler@googlemail.com>
Date: Wed, 7 Apr 2010 15:17:40 CST
Raw View
On 7 Apr., 19:38, german diago <germandi...@gmail.com> wrote:
> Looking at the latest c++0x draft, I saw that numeric_limits
> functions have throw() specifiers, which have been deprecated. Are
> this being changed by noexcept specifiers? Maybe they're changing it
> for the next draft? Thanks.

As of the current state the *only* explicit usage of noexcept
is that of the function template std::declval() from <utility> (in
particular see [declval]). Further-on, noexcept is used to specify
the semantics of several *_nothrow_* traits as part of the
type property predicates.

As a further step, dynamic-exception-specifications became
deprecated, so there are good chances that the library will
change it's current exception-specifications in this regard,
but I have no further concrete data available. I suggest that
you contact your responsible national body (association)
to add a comment that ensures that this will happen. There
may be a possible interpretation (but this requires at least
one sentence within clause 17 [library]) that a library implementation
may replace all current non-throwing exception-specifications
by explicit noexcept() specifications. This makes sense,
because both throw() and noexcept() are considered as
/compatible/ exception-specifications. Note that this doesn't
mean that they have the same effect, but that repeated
declarations of the same function may use either form.

HTH & Greetings from Bremen,

Daniel Kr   gler



--
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@netlab.cs.rpi.edu]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]





Author: Pete Becker <pete@versatilecoding.com>
Date: Thu, 8 Apr 2010 00:23:08 CST
Raw View
Daniel Kr=FCgler wrote:

> I suggest that
> you contact your responsible national body (association)
> to add a comment that ensures that this will happen.
>

Umm, a national body comment can *request* a change, but the committee isn'=
t
obligated to do it. And for something brand new like noexcept, I'd be
nervous about rewriting the library specification to use it. throw()
specifiers are still valid and meaningful. There's no urgent need to replac=
e
them.

--
 Pete
Roundhouse Consulting, Ltd. (www.versatilecoding.com) Author of
"The Standard C++ Library Extensions: a Tutorial and Reference"
(www.petebecker.com/tr1book)


[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use
mailto:std-c++@netlab.cs.rpi.edu<std-c%2B%2B@netlab.cs.rpi.edu>
]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]





Author: german diago <germandiago@gmail.com>
Date: Thu, 8 Apr 2010 12:38:04 CST
Raw View
> I suggest that
> you contact your responsible national body (association)
> to add a comment that ensures that this will happen.

How can I do this? Where should I go to? Thanks.

--
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use
mailto:std-c++@netlab.cs.rpi.edu<std-c%2B%2B@netlab.cs.rpi.edu>
]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]





Author: Anthony Williams <anthony.ajw@gmail.com>
Date: Thu, 8 Apr 2010 18:26:33 CST
Raw View
german diago <germandiago@gmail.com> writes:

>> I suggest that
>> you contact your responsible national body (association)
>> to add a comment that ensures that this will happen.
>
> How can I do this? Where should I go to? Thanks.

The details will vary between countries. In the UK, contact BSI, in
Germany contact DIN and in France contact AFNOR. In the US the NB is
INCITS. Other countries have their own National Bodies.

If you are unable to pass your comment to your own National Body for
whatever reason, the BSI C++ panel will take a look at your comment and
potentially add it to the list we submit. See my blog entry:

http://www.justsoftwaresolutions.co.uk/cplusplus/c++0x-now-at-fcd.html

Anthony
--
Author of C++ Concurrency in Action     http://www.stdthread.co.uk/book/
just::thread C++0x thread library             http://www.stdthread.co.uk
Just Software Solutions Ltd       http://www.justsoftwaresolutions.co.uk
15 Carrallack Mews, St Just, Cornwall, TR19 7UL, UK. Company No. 5478976

[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@netlab.cs.rpi.edu]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]