Boost logo

Boost :

From: William E. Kempf (williamkempf_at_[hidden])
Date: 2002-08-21 09:21:56


From: "David Abrahams" <dave_at_[hidden]>
> -w-8001 seems like a slam-dunk to me. Go ahead and patch borland-tools.jam
> if you like.
> -w-8080 seems a little bit less like a great idea. That warning can help
to
> keep flotsam and jetsam out of our code.
>
> There are several ways to suppress unused variable warnings explicitly:
>
> (void)x; // works with most compilers
>
>
> template <class T> inline void unused(T const&) {}
> unused(x); // works with all compilers, AFAIK

And I suggested adding this construct to Boost at one point. I'd like to
re-raise that suggestion. Though it's not precisely a config concept, it is
used solely to suppress warnings usually caused by "portable" constructs, so
I'd be happy to see this in <boost/config.hpp>, though anywhere else would
work as well.

Bill Kempf


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