Commit Graph

9 Commits

Author SHA1 Message Date
Yaakov Selkowitz 9087163804 ansification: remove _DEFUN
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
2018-01-17 11:47:26 -06:00
Yaakov Selkowitz 9db7609592 ctype: remove TRAD_SYNOPSIS
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
2017-12-01 03:41:50 -06:00
Thomas Preudhomme 0e2e3c958c Fix pdf build failure wrt documentation of is*_l functions
make pdf on arm-none-eabi targets fails to build after the reorganization in
baf0c9fcb5 to fold is*_l documentation in their
is* counterpart. This is due two issues:

1) newlib/libc/ctype/ctype.tex still including the def file for the long versions
2) missing angle brackets in .c files for some of is*_l functions

This patch fixes the issues and allows make pdf to succeeds.
2016-08-17 20:58:21 +02:00
Corinna Vinschen baf0c9fcb5 Fold documentation of is*_l funcs into documentation of non-l is* funcs
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2016-08-15 14:21:52 +02:00
Corinna Vinschen d16a56306d Consolidate wctomb/mbtowc calls for POSIX-1.2008
- Remove charset parameter from low level __foo_wctomb/__foo_mbtowc calls.
- Instead, create array of function for ISO and Windows codepages to point
  to function which does not require to evaluate the charset string on
  each call.  Create matching helper functions.  I.e., __iso_wctomb,
  __iso_mbtowc, __cp_wctomb and __cp_mbtowc are functions returning the
  right function pointer now.
- Create __WCTOMB/__MBTOWC macros utilizing per-reent locale and replace
  calls to __wctomb/__mbtowc with calls to __WCTOMB/__MBTOWC.
- Drop global __wctomb/__mbtowc vars.
- Utilize aforementioned changes in Cygwin to get rid of charset in other,
  calling functions and simplify the code.
- In Cygwin restrict global cygheap locale info to the job performed
  by internal_setlocale.  Use UTF-8 instead of ASCII on the fly in
  internal conversion functions.
- In Cygwin dll_entry, make sure to initialize a TLS area with a NULL
  _REENT->_locale pointer.  Add comment to explain why.

Signed-off by: Corinna Vinschen <corinna@vinschen.de>
2016-08-15 10:56:57 +02:00
Corinna Vinschen a6a477fa81 POSIX-1.2008 per-thread locales, groundwork part 1
Introduce first cut of struct _thr_locale_t used for the locale_t definition.
Introduce global instance called __global_locale used by default.
Introduce internal inline functions __get_global_locale, __get_locale_r,
__get_current_locale.

Remove usage of global variables in favor of accessor functions pointing to
__global_locale for now.  Include all local headers in locale subdir from
setlocale.h to get single include for internal locale access.

Introduce __CTYPE_PTR macro to replace direct access to __ctype_ptr__
and use throughout in isxxx functions.

Signed-off by: Corinna Vinschen <corinna@vinschen.de>
2016-08-15 10:56:56 +02:00
Corinna Vinschen cc88e009ed * libc/ctype/isalnum.c: Correct domain of definition to SUSv4 wording.
* libc/ctype/isalpha.c: Ditto.
	* libc/ctype/isblank.c: Ditto.
	* libc/ctype/iscntrl.c: Ditto.
	* libc/ctype/isdigit.c: Ditto.
	* libc/ctype/islower.c: Ditto.
	* libc/ctype/isprint.c: Ditto.
	* libc/ctype/ispunct.c: Ditto.
	* libc/ctype/isxdigit.c: Ditto.
2013-05-23 14:46:51 +00:00
Jeff Johnston fa914bf8ab 2008-07-21 Jeff Johnston <jjohnstn@redhat.com>
* libc/ctype/ctype_.c: Add new pointer __ctype_ptr__ which is one
        less than the old __ctype_ptr.
        * libc/ctype/isalnum.c: Use __ctype_ptr__.
        * libc/ctype/isalpha.c: Ditto.
        * libc/ctype/iscntrl.c: Ditto.
        * libc/ctype/isdigit.c: Ditto.
        * libc/ctype/islower.c: Ditto.
        * libc/ctype/isprint.c: Ditto.
        * libc/ctype/ispunct.c: Ditto.
        * libc/ctype/isspace.c: Ditto.
        * libc/ctype/isupper.c: Ditto.
        * libc/ctype/isxdigit.c: Ditto.
        * libc/include/ctype.h: Change ctype macros to use new __ctype_ptr__
        and add declaration of __ctype_ptr__.  Remove older ctype table pointers
        from here even though they can still work.
2008-07-21 21:28:34 +00:00
Christopher Faylor 8a0efa53e4 import newlib-2000-02-17 snapshot 2000-02-17 19:39:52 +00:00