Re: Function call

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

 



Hello Subbulakshmi,


On Wed, 1 Mar 2006 10:54:03 +0530 "Subbulakshmi Sadagopal (RBIN/EDS2) *" <Subbulakshmi.S@xxxxxxxxxxxx> wrote:

> 
> Hello,
> 
> I have a doubt regarding the following code. There is a void function
> funckey().
> 
> void funckey()
> {
> ;
> }
> 
> void main()
> {
> funckey;
> funckey();
> }
> 
> During execution, the second statement calls the function funckey().
> 
> What does the compiler do in the first statement funckey?

It evaluates the expression "funckey", which is just a pointer to a function
(as char* foo; is a pointer to char). Function names can be used in some few
situations (passed as parameter to some functions for signal/callback
hooking for instance).


Regards,

-- 
wwp

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Assembler]     [Git]     [Kernel List]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [C Programming]     [Yosemite Campsites]     [Yosemite News]     [GCC Help]

  Powered by Linux