[Libreoffice] [Patch][EasyHacks] Replace ScfRef with boost::shared_ptr in calc filter code

Nigel Hawkins n.hawkins at gmx.com
Sat Nov 20 00:52:09 PST 2010

On Fri, 2010-11-19 at 20:31 -0500, Kohei Yoshida wrote:
> Great work!  I've applied all your patches and committed as a single
> commit.  I hope that's okay.  

Not a problem. I generally commit locally in very small chunks and then
format-patch generates one patch per commit. I can squash them together
in future if that is the preferred style.
> Here, you replaced all instances of xFoo.is() with xFoo.get(), which is
> itself not incorrect.  But boost::shared_ptr overloads the operator
> bool() which returns the wrapped pointer value when a boolean value is
> expected, so in this example simply replacing xFoo.is() with xFoo is
> sufficient (and cleaner).  I've made this change while applying your
> last patch.

I have learnt something new today, so this is good. Having said that,
even after reading about the safe bool idiom, "operator
unspecified_bool_type" still seems a bit obscure.


More information about the LibreOffice mailing list