Boost logo

Boost :

Subject: Re: [boost] [c++1] BOOST_NOEXCEPT macros?
From: Beman Dawes (bdawes_at_[hidden])
Date: 2011-10-10 11:55:54


On Mon, Oct 10, 2011 at 4:52 AM, Domagoj Saric
<domagoj.saric_at_[hidden]> wrote:

> Didn't find that thread so I apologize if it was already discussed

See http://lists.boost.org/Archives/boost/2011/02/177284.php and replies.

> couldn't you add compiler specific versions [e.g. __declspec( nothrow ),
> __attribute(( nothrow ))...] for the non predicate/expression version?

That thread discussed the possibility of the C++03 version using
throw() for MSVC and __attribute__((nothrow)) for GCC.

The uses I'm making of it are for cases where there is nothing in the
current code, and the docs say "Throws: Nothing".

I guess we could provide yet another form that handled the
BOOST_NOEXCEPT_OR_EMPTY_THROWS case, but I'm not greatly interested in
working that one out. If someone else wants to take that on, fine.
Hopefully a shorter name could be found. Maybe BOOST_NEVER_THROWS.

--Beman


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk