home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / libg++-2.7.1-bin.lha / lib / g++-include / std / sinst.h < prev    next >
C/C++ Source or Header  |  1996-10-12  |  3KB  |  74 lines

  1. // Forward declarations of -*- C++ -*- string instantiations.
  2. // Copyright (C) 1994 Free Software Foundation
  3.  
  4. // This file is part of the GNU ANSI C++ Library.  This library is free
  5. // software; you can redistribute it and/or modify it under the
  6. // terms of the GNU General Public License as published by the
  7. // Free Software Foundation; either version 2, or (at your option)
  8. // any later version.
  9.  
  10. // This library is distributed in the hope that it will be useful,
  11. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  13. // GNU General Public License for more details.
  14.  
  15. // You should have received a copy of the GNU General Public License
  16. // along with this library; see the file COPYING.  If not, write to the Free
  17. // Software Foundation, 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
  18.  
  19. // As a special exception, if you link this library with files
  20. // compiled with a GNU compiler to produce an executable, this does not cause
  21. // the resulting executable to be covered by the GNU General Public License.
  22. // This exception does not however invalidate any other reasons why
  23. // the executable file might be covered by the GNU General Public License.
  24.  
  25. // Written by Jason Merrill based upon the specification by Takanori Adachi
  26. // in ANSI X3J16/94-0013R2.
  27.  
  28. #ifndef __SINST__
  29. #define __SINST__
  30.  
  31. extern "C++" {
  32. #define __S basic_string<char,string_char_traits<char> >
  33. //#define __W basic_string<wchar_t,string_char_traits<wchar_t> >
  34.  
  35. extern template class __bsrep<char, string_char_traits<char> >;
  36. extern template class __S;
  37. // extern template class __W;
  38. // extern template class __bsrep<wchar_t, string_char_traits<wchar_t> >;
  39.  
  40. #define __DOPR(op, ret, c, s) \
  41.   extern template ret operator op (const s&, const s&); \
  42.   extern template ret operator op (const c*, const s&); \
  43.   extern template ret operator op (const s&, const c*); \
  44.  
  45. #define __DO(op, ret, c, s) \
  46.   extern template ret operator op (const s&, const s&); \
  47.   extern template ret operator op (const c*, const s&); \
  48.   extern template ret operator op (const s&, const c*); \
  49.   extern template ret operator op (c, const s&); \
  50.   extern template ret operator op (const s&, c);
  51.  
  52. __DO (+, __S, char, __S)
  53. // __DO (+, __W, wchar_t, __W) */
  54.  
  55. #define __DOB(op) \
  56.   __DOPR (op, bool, char, __S)
  57. //  __DOPR (op, bool, wchar_t, __W)
  58.  
  59. __DOB (==)
  60. __DOB (!=)
  61. __DOB (<)
  62. __DOB (>)
  63. __DOB (<=)
  64. __DOB (>=)
  65.  
  66. #undef __S
  67. //#undef __W
  68. #undef __DO
  69. #undef __DOB
  70. #undef __DOPR
  71. } // extern "C++"
  72.  
  73. #endif
  74.