Re: GTK_WINDOW(NULL) (WAS: more patches)



"Craig M. Buchek" <craig buchek com> writes: 
> What if GTK_WINDOW() and friends returned NULL when they are passed
> NULL?
> 
> It seems that passing a NULL in place of a widget pointer is a common
> thing. And casting a NULL is generally a safe operation. I realize that
> the casting macros also check for the object type, but in many
> situations a NULL object is considered to be a member of any type.

The cast macros are intended in part to verify that the object exists
and is non-NULL, there's no point in using them for NULL objects (you
can't check the type of NULL anyhow).

Havoc




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