home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!pipex!warwick!bham!pickerig
- From: pickerig@eee.bham.ac.uk (Guy Pickering)
- Newsgroups: comp.lang.c++
- Subject: Was: Template Use <sigh>
- Date: 22 Jan 1993 15:48:29 GMT
- Organization: The University of Birmingham, England
- Lines: 36
- Message-ID: <1jp50dINNk34@rs6000.bham.ac.uk>
- NNTP-Posting-Host: nanda_devi.eee.bham.ac.uk
- X-Newsreader: TIN [version 1.1 PL6]
-
- Firstly, thank you to all those who replied...I am at least half way
- there, but wondering if brute force and ignorance isn't the answer.
-
- Anyway, my problem in more detail is this: I have three directories
- which contain the following:
-
- 1/ The .C and .H files defining the template class LookupTable.
- 2/ The .C and .H files of an algorithm which uses LookupTable<unsigned
- char>
- 3/ A main.C which binds the whole lot together, but does not itself
- use LookupTable<unsigned char>
-
- The problem is that at link time, no template instantiation takes
- place and then the real linker complains about all my member functions
- of LookupTable<unsigned char> being unresolved.
-
- The AT&T C++ manual says:
-
- If there are any unresolved symbols, the instantiator builds a list of
- class templates and function templates that must be instantiated....
-
- There are unresolved symbols, yet the instantiator doesn't do anything
- about them.
-
- What am I doing wrong??? Any ideas?
-
- Guy.
-
- --
- +--------------------------------+-----------------------------------------+
- | Guy Pickering | School of Electronic & Electrical Eng, |
- | E-MAIL: G.PICKERING@uk.ac.bham | University of Birmingham, |
- | Tel: (021) 414 4340 | Edgbaston, Birmingham. B15 2TT. |
- +--------------------------------+-----------------------------------------+
-
-
-