home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.unix.aix
- From: phil@dhcs.demon.co.uk (phil)
- Path: sparky!uunet!pipex!demon!dhcs.demon.co.uk!bill!phil
- Subject: Re: static data no in the symbol table?
- In-Reply-To: rr2b+@andrew.cmu.edu's message of 6 Jan 93 12:34:14 GMT
- Nntp-Posting-Host: lurch
- Organization: IISC, dept of hackery.
- References: <YfGptaS00Woi9TznQf@andrew.cmu.edu>
- Apparently-To: mail2news@news.demon.co.uk
- Date: Thu, 7 Jan 1993 14:21:46 +0000
- Message-ID: <PHIL.93Jan7133044@lurch.dhcs.demon.co.uk>
- Sender: usenet@demon.co.uk
- Lines: 27
-
- In article <YfGptaS00Woi9TznQf@andrew.cmu.edu> rr2b+@andrew.cmu.edu (Robert Andrew Ryan) writes:
-
- It appears that under some circumstances xlc fails to output symbols for
- static data. For example, compiling:
- .....
- static struct classheader atom_classheader = {
- 4,
- "atom",
- "atom",
- 0x92382,
- };
- .......
-
-
- If atom_classheader is never referenced, I believe that the compiler is
- intelligent enough to regard this as a waste of space and not output this to
- the object file. This is really irritating if the string is something useful,
- such as:
-
- static char SccsId[] = "@(#)foo.c 4.1" ;
-
- For the above, the way round it is to declare the following:
-
- static char *SccsId[] = { "@(#)foo.c 4.1" } ;
-
- The compiler seems to let this through.
-
-