Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!apple!rutgers!att!ulysses!andante!alice!ark From: ark@alice.UUCP (Andrew Koenig) Newsgroups: comp.lang.c Subject: Re: C linkage query Message-ID: <9467@alice.UUCP> Date: 13 Jun 89 01:01:22 GMT References: <9449@alice.UUCP> <186@cbnewsd.ATT.COM> Organization: AT&T Bell Laboratories, Liberty Corner NJ Lines: 16 In article <186@cbnewsd.ATT.COM>, tainter@cbnewsd.ATT.COM (johnathan.tainter) writes: > In article <1795@auspex.auspex.com> guy@auspex.auspex.com (Guy Harris) writes: > >I.e., if you compile a file containing > > extern int foo; > > main() {} > >and link that *with no other object files and with no libraries that > >define "foo"*, will the link fail? I recently asked a similar question. I have since learned that this is explicitly legal in ANSI C. The only compilers people have mentioned that DON'T handle it correctly are on desktop micros of various sorts. -- --Andrew Koenig ark@europa.att.com