X-Authentication-Warning: delorie.com: mailnull set sender to djgpp-bounces using -f From: Dong Soo Kim Newsgroups: comp.os.msdos.djgpp Subject: template functions .. Date: Thu, 10 Jan 2002 12:38:47 +1100 Organization: The University of New South Wales Lines: 30 Message-ID: NNTP-Posting-Host: hummel.orchestra.cse.unsw.edu.au Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: tomahawk.unsw.edu.au 1010626641 24411 129.94.242.21 (10 Jan 2002 01:37:21 GMT) X-Complaints-To: abuse AT unsw DOT edu DOT au NNTP-Posting-Date: Thu, 10 Jan 2002 01:37:21 +0000 (UTC) X-X-Sender: dsk666 AT hummel DOT orchestra DOT cse DOT unsw DOT EDU DOT AU To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Hi all, I'm trying to learn C++ atm and I've hit a slight problem .. template functions don't seem to work at all. Looked in the archive and found that all the past problems seem to be related to multifile programs. You can look at the program at www.cse.unsw.edu.au/~dsk666/19-4.cpp It's a single file program that basically does some sorting using functions defined from a template, nothing too tricky .. The error generated is : Compiling: 19-4.cpp no errors Creating: 19-4.exe Error: obj/19-4.o: In function `main': 19-4.cpp(16) Error: undefined reference to `sortnums(char *)' 19-4.cpp(17) Error: undefined reference to `sortnums(int *)' 19-4.cpp(18) Error: undefined reference to `sortnums(float *)' There were some errors can somebody enlighten me? thanks in advance DSK