Re: a basic doubt on static functions...
From: Byron A Jeff (byron_at_cc.gatech.edu)
Date: 01/27/05
- Next message: adityavasishth_at_gmail.com: "Re: main() function in the Kernel source code"
- Previous message: shiva: "a basic doubt on static functions..."
- In reply to: shiva: "a basic doubt on static functions..."
- Next in thread: Tauno Voipio: "Re: a basic doubt on static functions..."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 27 Jan 2005 07:34:03 -0500
In article <1106827929.401971.22820@c13g2000cwb.googlegroups.com>,
shiva <nikhilbhargav_nsit@indiatimes.com> wrote:
>hello all,
>
>I have aa basic doubt about declaring function as static. What
>difference is between following two declarations
>
>static __inline__ void wait_ms(unsigned int ms);
>
>__inline__ void wait_ms(unsigned int ms);
This is really a C question which should be in comp.lang.c
static for functions changes the visibility of the function.
By default functions a visible and accessible anywhere in an
application, even if the function resides in another source file.
static limits the visibility of the function to the source file
that it's declared in.
BTW I have a unrelated question: Is there a particular reason
that certain speaker/writers of English, particularly as a
second language, use the word "doubt" in place of "question"?
It's something I've noticed over the years, and I was just curious
as to how this substitution came to be.
BAJ
- Next message: adityavasishth_at_gmail.com: "Re: main() function in the Kernel source code"
- Previous message: shiva: "a basic doubt on static functions..."
- In reply to: shiva: "a basic doubt on static functions..."
- Next in thread: Tauno Voipio: "Re: a basic doubt on static functions..."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|