Boost logo

Boost :

Subject: Re: [boost] [rfc] rcpp
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2010-02-27 17:59:38


Daniel Trebbien wrote:
> What is the safe_bool stuff for; or, why have you implemented
> `operator sb_type() const` rather than `operator bool() const` for
> evaluating a `resource` as a `bool`?

This is a common idiom to prevent problems from the fact that
bool can convert to int.

In Christ,
Steven Watanabe

Boost list run by bdawes at, gregod at, cpdaniel at, john at