On Wed, Feb 16, 2005 at 11:55:09AM -0500, mental@...3... wrote:
Quoting Bryce Harrington <bryce@...260...>:
So something like this?
gboolean lastViewOfDocument(SPDocument* doc, SPDesktop* view) const;
Nearly. Two things:
- s/gboolean/bool/
In general do we prefer bool over gboolean? I notice many instances of gboolean in the Gtk+ code, should I be changing those to bool as I reimplement them in Gtkmm?
Bryce
On Sun, 2005-04-10 at 03:26, Bryce Harrington wrote:
In general do we prefer bool over gboolean? I notice many instances of gboolean in the Gtk+ code, should I be changing those to bool as I reimplement them in Gtkmm?
Yes!
gboolean is troublesome as it doesn't maintain the (sort of) expected invariant that ( value == 1 ) == value, and we've had a few bugs due to that over the years. C++'s bool type does.
That aside, using standard language types is preferable anyway. A lot of the SPDesktop etc stuff shouldn't really need to rely on glib/glibmm for anything.
-mental
participants (2)
-
Bryce Harrington
-
MenTaLguY