On Tue, 30 Mar 2010 16:01:10 -0400 José Alburquerque <[email protected]> wrote:
> > El Mar 30, 2010, a las 2:37 PM, Chris Vine > <[email protected]> escribió: > > > On Tue, 30 Mar 2010 16:19:44 +0200 > > Murray Cumming <[email protected]> wrote: > >> It would be nice if someone played with using these new features in > >> gtkmm. For intsance, create a git branch and try to replace use of > >> Glib::RefPtr<Thing> with auto wherever possible. > > > > You shouldn't need to change anything. Glib::RefPtr is only used by > > gtkmm as far as I am aware in return values and as function > > arguments. You should be able to use the auto keyword now with any > > gtkmm function returning a RefPtr, with gcc-4.3 and greater with > > the -std=gnu++0x flag > > for the compiler. (Note I said "should" - I haven't tried it.) > > > > The auto keyword doesn't obviate the need to specify the function > > prototype: that is necessary for type inference to work. > > What could be changed, as Murray already said, are the examples in > the gtkmm-documentation module. It could be worthwhile to see if > the examples could be modified to use these upcoming C++ features. Provided it does not make the library uncompilable for anyone using a c++98/03 compiler. I don't think it would be right to make the library unusable for those people, just for the purpose of showing others in the examples how to use the extended auto keyword in c++0x. I cannot now remember how easy it is to switch off compilation of the examples. It used to be the default: I am not sure if it still is. Chris _______________________________________________ gtkmm-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/gtkmm-list
