ctype_base.h revision 132720
138032Speter// Locale support -*- C++ -*-
264562Sgshapiro
364562Sgshapiro// Copyright (C) 2001, 2003 Free Software Foundation, Inc.
438032Speter//
538032Speter// This file is part of the GNU ISO C++ Library.  This library is free
638032Speter// software; you can redistribute it and/or modify it under the
738032Speter// terms of the GNU General Public License as published by the
838032Speter// Free Software Foundation; either version 2, or (at your option)
938032Speter// any later version.
1038032Speter
1138032Speter// This library is distributed in the hope that it will be useful,
1238032Speter// but WITHOUT ANY WARRANTY; without even the implied warranty of
1338032Speter// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1438032Speter// GNU General Public License for more details.
1566494Sgshapiro
1664562Sgshapiro// You should have received a copy of the GNU General Public License along
1738032Speter// with this library; see the file COPYING.  If not, write to the Free
1864562Sgshapiro// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
1938032Speter// USA.
2064562Sgshapiro
2164562Sgshapiro// As a special exception, you may use this file as part of a free software
2264562Sgshapiro// library without restriction.  Specifically, if other files instantiate
2364562Sgshapiro// templates or use macros or inline functions from this file, or you compile
2464562Sgshapiro// this file and link it with other files to produce an executable, this
2564562Sgshapiro// file does not by itself cause the resulting executable to be covered by
2664562Sgshapiro// the GNU General Public License.  This exception does not however
2764562Sgshapiro// invalidate any other reasons why the executable file might be covered by
2864562Sgshapiro// the GNU General Public License.
2964562Sgshapiro
3064562Sgshapiro//
3164562Sgshapiro// ISO C++ 14882: 22.1  Locales
3264562Sgshapiro//
3364562Sgshapiro
3464562Sgshapiro  struct ctype_base
3538032Speter  {
3638032Speter    typedef unsigned short 	mask;
3738032Speter
3838032Speter    // Non-standard typedefs.
3938032Speter    typedef unsigned char *     __to_type;
4038032Speter
4138032Speter    // NB: Offsets into ctype<char>::_M_table force a particular size
4238032Speter    // on the mask type. Because of this, we don't use an enum.
4338032Speter    static const mask space = __dj_ISSPACE;	// Whitespace
4438032Speter    static const mask print = __dj_ISPRINT;	// Printing
4538032Speter    static const mask cntrl = __dj_ISCNTRL;	// Control character
4638032Speter    static const mask upper = __dj_ISUPPER;	// UPPERCASE
4738032Speter    static const mask lower = __dj_ISLOWER;	// lowercase
4838032Speter    static const mask alpha = __dj_ISALPHA;	// Alphabetic
4938032Speter    static const mask digit = __dj_ISDIGIT;	// Numeric
5038032Speter    static const mask punct = __dj_ISPUNCT;     // Punctuation
5138032Speter    static const mask xdigit = __dj_ISXDIGIT;   // Hexadecimal numeric
5238032Speter    static const mask alnum = __dj_ISALPHA | __dj_ISDIGIT;  // Alphanumeric
5338032Speter    static const mask graph = __dj_ISALPHA | __dj_ISDIGIT | __dj_ISPUNCT;  // Graphical
5438032Speter  };
5538032Speter
5638032Speter
5738032Speter
5838032Speter