Hi,
  I am going to repeat my question and try to clarify
it further. 

We know that in any program, whenever we call a
function, we have to pass some data to that
function and then only that function can use that
data.

In my program (that I posted earlier), The function to
be called is:
-----------------------------------
void hello( GtkWidget *widget,
            gpointer   data )
{
    g_print ("Hello World\n");
}
-----------------------------------
On the other hand, In the main() we are calling this
function as follows:

    gtk_signal_connect (GTK_OBJECT (button),"clicked",
                        GTK_SIGNAL_FUNC (hello),
                         NULL);


Now my question is as follows: 

We are passing NULL as data to the function
"hello". Yet, hello function (as declared above) is
showing that it has been passed two arguments, the
widget and the gpointer.
Why doesn't the compiler complain that you are passing
NULL to the function and then you are trying to use
arguments in the function?

Thanks
Shiraz


__________________________________________________
Do You Yahoo!?
Great stuff seeking new owners in Yahoo! Auctions! 
http://auctions.yahoo.com
_______________________________________________
gtk-list mailing list
[EMAIL PROTECTED]
http://mail.gnome.org/mailman/listinfo/gtk-list

Reply via email to