Print this page
remove support for non-ANSI compilation


   8  *
   9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  10  * or http://www.opensolaris.org/os/licensing.
  11  * See the License for the specific language governing permissions
  12  * and limitations under the License.
  13  *
  14  * When distributing Covered Code, include this CDDL HEADER in each
  15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16  * If applicable, add the following below this CDDL HEADER, with the
  17  * fields enclosed by brackets "[]" replaced with your own identifying
  18  * information: Portions Copyright [yyyy] [name of copyright owner]
  19  *
  20  * CDDL HEADER END
  21  */
  22 /*
  23  * Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
  24  * Use is subject to license terms.
  25  */
  26 
  27 /*
  28  * Copyright 2013 Garrett D'Amore <garrett@damore.org>
  29  *
  30  * Portions of this file developed by Garrett D'Amore are licensed
  31  * under the terms of the Common Development and Distribution License (CDDL)
  32  * version 1.0 only.  The use of subsequent versions of the License are
  33  * is specifically prohibited unless those terms are not in conflict with
  34  * version 1.0 of the License.  You can find this license on-line at
  35  * http://www.illumos.org/license/CDDL
  36  */
  37 
  38 #ifndef _LOCALE_H
  39 #define _LOCALE_H
  40 
  41 #include <iso/locale_iso.h>
  42 
  43 #if (!defined(_STRICT_STDC) && !defined(__XOPEN_OR_POSIX)) || \
  44         defined(__EXTENSIONS__)
  45 #include <libintl.h>
  46 #endif
  47 
  48 /*


  67 
  68 
  69 #if defined(_XPG7) || !defined(_STRICT_SYMBOLS)
  70 
  71 /*
  72  * These were added in POSIX 2008 as part of the newlocale() specification.
  73  */
  74 #define LC_CTYPE_MASK           (1 << LC_CTYPE)
  75 #define LC_NUMERIC_MASK         (1 << LC_NUMERIC)
  76 #define LC_TIME_MASK            (1 << LC_TIME)
  77 #define LC_COLLATE_MASK         (1 << LC_COLLATE)
  78 #define LC_MONETARY_MASK        (1 << LC_MONETARY)
  79 #define LC_MESSAGES_MASK        (1 << LC_MESSAGES)
  80 #define LC_ALL_MASK             (0x3f)
  81 
  82 #ifndef _LOCALE_T
  83 #define _LOCALE_T
  84 typedef struct _locale *locale_t;
  85 #endif
  86 
  87 #if     defined(__STDC__)
  88 extern locale_t duplocale(locale_t);
  89 extern void     freelocale(locale_t);
  90 extern locale_t newlocale(int, const char *, locale_t);
  91 extern locale_t uselocale(locale_t);
  92 #else   /* __STDC__ */
  93 extern locale_t duplocale();
  94 extern void     freelocale();
  95 extern locale_t newlocale();
  96 extern locale_t uselocale();
  97 #endif  /* __STDC__ */
  98 
  99 #define LC_GLOBAL_LOCALE        (__global_locale())
 100 extern locale_t                 __global_locale(void);
 101 
 102 #endif  /* defined(_XPG7) || !defined(_STRICT_SYMBOLS) */
 103 
 104 #ifdef  __cplusplus
 105 }
 106 #endif
 107 
 108 #endif  /* _LOCALE_H */


   8  *
   9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  10  * or http://www.opensolaris.org/os/licensing.
  11  * See the License for the specific language governing permissions
  12  * and limitations under the License.
  13  *
  14  * When distributing Covered Code, include this CDDL HEADER in each
  15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16  * If applicable, add the following below this CDDL HEADER, with the
  17  * fields enclosed by brackets "[]" replaced with your own identifying
  18  * information: Portions Copyright [yyyy] [name of copyright owner]
  19  *
  20  * CDDL HEADER END
  21  */
  22 /*
  23  * Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
  24  * Use is subject to license terms.
  25  */
  26 
  27 /*
  28  * Copyright 2014 Garrett D'Amore <garrett@damore.org>
  29  *
  30  * Portions of this file developed by Garrett D'Amore are licensed
  31  * under the terms of the Common Development and Distribution License (CDDL)
  32  * version 1.0 only.  The use of subsequent versions of the License are
  33  * is specifically prohibited unless those terms are not in conflict with
  34  * version 1.0 of the License.  You can find this license on-line at
  35  * http://www.illumos.org/license/CDDL
  36  */
  37 
  38 #ifndef _LOCALE_H
  39 #define _LOCALE_H
  40 
  41 #include <iso/locale_iso.h>
  42 
  43 #if (!defined(_STRICT_STDC) && !defined(__XOPEN_OR_POSIX)) || \
  44         defined(__EXTENSIONS__)
  45 #include <libintl.h>
  46 #endif
  47 
  48 /*


  67 
  68 
  69 #if defined(_XPG7) || !defined(_STRICT_SYMBOLS)
  70 
  71 /*
  72  * These were added in POSIX 2008 as part of the newlocale() specification.
  73  */
  74 #define LC_CTYPE_MASK           (1 << LC_CTYPE)
  75 #define LC_NUMERIC_MASK         (1 << LC_NUMERIC)
  76 #define LC_TIME_MASK            (1 << LC_TIME)
  77 #define LC_COLLATE_MASK         (1 << LC_COLLATE)
  78 #define LC_MONETARY_MASK        (1 << LC_MONETARY)
  79 #define LC_MESSAGES_MASK        (1 << LC_MESSAGES)
  80 #define LC_ALL_MASK             (0x3f)
  81 
  82 #ifndef _LOCALE_T
  83 #define _LOCALE_T
  84 typedef struct _locale *locale_t;
  85 #endif
  86 

  87 extern locale_t duplocale(locale_t);
  88 extern void     freelocale(locale_t);
  89 extern locale_t newlocale(int, const char *, locale_t);
  90 extern locale_t uselocale(locale_t);






  91 
  92 #define LC_GLOBAL_LOCALE        (__global_locale())
  93 extern locale_t                 __global_locale(void);
  94 
  95 #endif  /* defined(_XPG7) || !defined(_STRICT_SYMBOLS) */
  96 
  97 #ifdef  __cplusplus
  98 }
  99 #endif
 100 
 101 #endif  /* _LOCALE_H */