[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Lightweight Web browsers



Quoting mdanish@andrew.cmu.edu:

> Now I agree that there's lots of bloat in Gnome, but I have to disagree
> with you about Glib.  Glib provides many handy routines (such as linked
> list management, and a threads API) for C programmers.  Having Glib provide
> these routines is a much better choice than having each programmer write
> his or her own procedures to accomplish the same task.  It reduces
> duplicate
> code and provides what is probably a much more efficient set of routines
> than what most people would write (not to mention a consistent API).  It's
> bad enough that C has as many problems as it does, Glib is at least an
> attempt to make things more sane.

Well, I've heard these arguments a lot and I agree with them to some extent. I 
like several of the routines, but things such as g_malloc() and g_free() are 
equivilent to functions in the standard C libary. I am also very suprized that 
glib has types like gint, gshort, and gchar which are directly aliased to atomic 
types from the C language (guint32 for example is actually useful). gint is 
longer than 'int', won't get highlighted by default in an editor, and makes your 
code less portable away from glib.

I think in principle glib may be a good idea, but it is overdone.


-----------------------------------------------------------
This mail sent through the IMP demo site: demo.horde.org
     Find out more at http://www.horde.org/imp/



Reply to: