|
Boost Users : |
From: Douglas Gregor (gregod_at_[hidden])
Date: 2002-09-10 11:33:03
On Tuesday 10 September 2002 12:20 pm, Bertolt Mildner wrote:
> Arghalskfvbafg1q24584%&§/(%§&$%&?!?!
>
> CW now gives me the same error in operator safe_bool() ...
\me ponders running out to buy MW 8.2 just to get this working...
Yet one more idea (arghhhhh):
template<typename T>
struct dummy {
void nonnull();
};
typedef void (dummy<int>::*safe_bool)();
operator safe_bool() const
{ return this->empty? 0 : &dummy<int>::nonnull; }
bool operator!() const
{ return this->empty(); }
Doug
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net