home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / lang / cplus / 19756 < prev    next >
Encoding:
Internet Message Format  |  1993-01-22  |  1.3 KB

  1. Path: sparky!uunet!spool.mu.edu!agate!doc.ic.ac.uk!uknet!glasgow!unix.brighton.ac.uk!je
  2. From: je@unix.brighton.ac.uk (John English)
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: overloading templates
  5. Message-ID: <1993Jan22.144155.5663@unix.brighton.ac.uk>
  6. Date: 22 Jan 93 14:41:55 GMT
  7. References: <1993Jan22.010238.9059@cs.kuleuven.ac.be>
  8. Organization: University of Brighton, UK
  9. Lines: 38
  10.  
  11. pluym@cs.kuleuven.ac.be (Luc Pluym) writes:
  12. : FIRST QUESTION
  13. : ==============
  14. : Can I have 
  15. : template <class T1>
  16. : class A {...};
  17. : and
  18. : template <class T1,class T2>
  19. : class A {...};
  20. : at the same time?
  21.  
  22.     No. Templates can't be overloaded.
  23.  
  24. : SECOND QUESTION
  25. : ===============
  26. : Suppose I have
  27. : template <class T,int i>
  28. : class B {...};
  29. : and also
  30. : template<class T,double d>
  31. : class B {...};
  32.  
  33.     No. Templates can't be overloaded.
  34. -- 
  35. -------------------------------------------------------------------------------
  36. John English            | Fudd's first law of opposition:
  37. Dept. of Computing        |    If you push something hard enough, it
  38. University of Brighton        |    *will* fall over.
  39. E-mail: je@unix.brighton.ac.uk    | Testlicle's deviant to Fudd's law:
  40. Fax:    0273 642405        |    What goes in, must come out.
  41. -------------------------------------------------------------------------------
  42.