From: "Ming-Chia Jiang" <jmc@wire.cs.nthu.edu.tw>
To: gcc-help@gcc.gnu.org
Subject: extern functions in header file
Date: Fri, 10 Sep 2004 06:37:00 -0000 [thread overview]
Message-ID: <20040910062659.M23072@wire.cs.nthu.edu.tw> (raw)
Hi folks,
Is there any difference between declaring functions with prefix "extern" and
without "extern" keyword in header files??
For example, I define a function FUNC(void, int) in test.c. And test.c
includes the test.h with the following two conditions:
--test.h with extern--
extern void FUNC(void, int);
--test.h without extern--
void FUNC(void, int);
The output result seems no difference, and also the compiler does not show
warning messages for both cases. Can anyone advise what the 'extern' keyword
effects in the header file?
Best Regards
Ming-Chia
next reply other threads:[~2004-09-10 6:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-10 6:37 Ming-Chia Jiang [this message]
2004-09-10 10:40 ` Eljay Love-Jensen
2004-09-10 11:04 ` Sriharsha Vedurmudi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040910062659.M23072@wire.cs.nthu.edu.tw \
--to=jmc@wire.cs.nthu.edu.tw \
--cc=gcc-help@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).