home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / gnu / g / bug / 2321 < prev    next >
Encoding:
Text File  |  1993-01-25  |  2.0 KB  |  66 lines

  1. Path: sparky!uunet!paladin.american.edu!howland.reston.ans.net!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!cis.ohio-state.edu!mistral.greco-prog.fr!miniussi
  2. From: miniussi@mistral.greco-prog.fr (Alain MINIUSSI [91-92])
  3. Newsgroups: gnu.g++.bug
  4. Subject: bug report
  5. Date: 25 Jan 1993 20:13:46 -0500
  6. Organization: GNUs Not Usenet
  7. Lines: 53
  8. Sender: daemon@cis.ohio-state.edu
  9. Approved: bug-g++@prep.ai.mit.edu
  10. Distribution: gnu
  11. Message-ID: <9301231852.AA01763@mistral.labri>
  12.  
  13. I think that the following code is legal:
  14.  
  15. ----------
  16.  
  17. #include <stream.h>
  18.  
  19. template <class T>
  20. class C {
  21.   class B<T>; 
  22. friend B<T>;  
  23.  
  24. public: 
  25.   C() {};
  26.   ~C() {};
  27. };
  28.  
  29. main()
  30. {
  31.   C<int> ;
  32. }
  33.  
  34. -------------------------
  35.  
  36. The compiler output is:
  37.  
  38. geocub>CC : g++ truc.cc -c -v
  39. Reading specs from /usr/local/lib/gcc-lib/sun4/2.3.3/specs
  40. gcc version 2.3.3
  41.  /usr/local/lib/gcc-lib/sun4/2.3.3/cpp -lang-c++ -v -undef -D__GNUC__=2 -D__GNUG__=2 -D__cplusplus -D
  42. sparc -Dsun -Dunix -D__sparc__ -D__sun__ -D__unix__ -D__sparc -D__sun -D__unix truc.cc /usr/tmp/cca05
  43. 965.i
  44. GNU CPP version 2.3.3 (sparc)
  45.  /usr/local/lib/gcc-lib/sun4/2.3.3/cc1plus /usr/tmp/cca05965.i -quiet -dumpbase truc.cc -version -o /
  46. usr/tmp/cca05965.s
  47. GNU C++ version 2.3.3 (sparc) compiled by GNU C version 2.3.3.
  48. truc.cc:7: parse error before `<'
  49. truc.cc:8: Internal compiler error.
  50. truc.cc:8: Please report this to `bug-g++@prep.ai.mit.edu'.
  51. geocub>CC :
  52.  
  53. Alain
  54.  
  55. ------------------------------------------------------------------------------
  56. Alain Miniussi                       | Je distingue les genies doues et les 
  57. (avec le "i" avant le "u")           | genies pas doues, "le genie est une 
  58. e-mail: miniussi@labri.greco-prog.fr | longue patience", c'est une reflexion
  59. LaBRI, Univ. BORDEAUX I              | de genie pas doue.     B. Vian
  60. 351, cours de la Liberation          | 
  61. 33405 TALENCE Cedex                  | (D'ailleurs, c'est souvent une longue
  62. FRANCE                               |  patience de la part des autres) Id
  63. ------------------------------------------------------------------------------
  64.  
  65.  
  66.