This commit is contained in:
hyung-hwan 2008-08-21 04:00:22 +00:00
parent 01dd1ad765
commit 6dbf01ade0
5 changed files with 1 additions and 303 deletions

View File

@ -1,34 +0,0 @@
/*
* $Id: ctype.h 223 2008-06-26 06:44:41Z baconevi $
*/
#ifndef _ASE_UTL_CTYPE_H_
#define _ASE_UTL_CTYPE_H_
#include <ase/types.h>
#include <ase/macros.h>
#ifdef __cplusplus
extern "C" {
#endif
ase_bool_t ase_isupper (ase_cint_t c);
ase_bool_t ase_islower (ase_cint_t c);
ase_bool_t ase_isalpha (ase_cint_t c);
ase_bool_t ase_isdigit (ase_cint_t c);
ase_bool_t ase_isxdigit (ase_cint_t c);
ase_bool_t ase_isalnum (ase_cint_t c);
ase_bool_t ase_isspace (ase_cint_t c);
ase_bool_t ase_isprint (ase_cint_t c);
ase_bool_t ase_isgraph (ase_cint_t c);
ase_bool_t ase_iscntrl (ase_cint_t c);
ase_bool_t ase_ispunct (ase_cint_t c);
ase_cint_t ase_toupper (ase_cint_t c);
ase_cint_t ase_tolower (ase_cint_t c);
#ifdef __cplusplus
}
#endif
#endif

View File

@ -1,24 +0,0 @@
/*
* $Id: helper.h 329 2008-08-16 14:08:53Z baconevi $
*/
#ifndef _ASE_UTL_HELPER_H_
#define _ASE_UTL_HELPER_H_
#include <ase/types.h>
#include <ase/macros.h>
#define ASE_GETCCLS() (ase_ccls)
#define ASE_SETCCLS(c) ((ase_ccls) = (c))
#ifdef __cplusplus
extern "C" {
#endif
extern ase_ccls_t* ase_ccls;
#ifdef __cplusplus
}
#endif
#endif

View File

@ -1,152 +0,0 @@
/*
* $Id: ctype.c 132 2008-03-17 10:27:02Z baconevi $
*
* {License}
*/
#include <ase/utl/ctype.h>
#if defined(ASE_CHAR_IS_MCHAR)
#include <ctype.h>
ase_bool_t ase_isupper (ase_cint_t c)
{
return isupper (c);
}
ase_bool_t ase_islower (ase_cint_t c)
{
return islower (c);
}
ase_bool_t ase_isalpha (ase_cint_t c)
{
return isalpha (c);
}
ase_bool_t ase_isdigit (ase_cint_t c)
{
return isdigit (c);
}
ase_bool_t ase_isxdigit (ase_cint_t c)
{
return isxdigit (c);
}
ase_bool_t ase_isalnum (ase_cint_t c)
{
return isalnum (c);
}
ase_bool_t ase_isspace (ase_cint_t c)
{
return isspace (c);
}
ase_bool_t ase_isprint (ase_cint_t c)
{
return isprint (c);
}
ase_bool_t ase_isgraph (ase_cint_t c)
{
return isgraph (c);
}
ase_bool_t ase_iscntrl (ase_cint_t c)
{
return iscntrl (c);
}
ase_bool_t ase_ispunct (ase_cint_t c)
{
return ispunct (c);
}
ase_cint_t ase_toupper (ase_cint_t c)
{
return toupper (c);
}
ase_cint_t ase_tolower (ase_cint_t c)
{
return tolower (c);
}
#elif defined(ASE_CHAR_IS_WCHAR)
#include <ctype.h>
#include <wctype.h>
ase_bool_t ase_isupper (ase_cint_t c)
{
return iswupper (c);
}
ase_bool_t ase_islower (ase_cint_t c)
{
return iswlower (c);
}
ase_bool_t ase_isalpha (ase_cint_t c)
{
return iswalpha (c);
}
ase_bool_t ase_isdigit (ase_cint_t c)
{
return iswdigit (c);
}
ase_bool_t ase_isxdigit (ase_cint_t c)
{
return iswxdigit (c);
}
ase_bool_t ase_isalnum (ase_cint_t c)
{
return iswalnum (c);
}
ase_bool_t ase_isspace (ase_cint_t c)
{
return iswspace (c);
}
ase_bool_t ase_isprint (ase_cint_t c)
{
return iswprint (c);
}
ase_bool_t ase_isgraph (ase_cint_t c)
{
return iswgraph (c);
}
ase_bool_t ase_iscntrl (ase_cint_t c)
{
return iswcntrl (c);
}
ase_bool_t ase_ispunct (ase_cint_t c)
{
return iswpunct (c);
}
ase_cint_t ase_toupper (ase_cint_t c)
{
return towupper (c);
}
ase_cint_t ase_tolower (ase_cint_t c)
{
return towlower (c);
}
#else
#error unsupported character type
#endif

View File

@ -1,92 +0,0 @@
/*
* $Id: helper.c 329 2008-08-16 14:08:53Z baconevi $
*/
#include <ase/utl/helper.h>
#include <ase/utl/ctype.h>
static ase_bool_t ccls_isupper (void* custom, ase_cint_t c)
{
return ase_isupper (c);
}
static ase_bool_t ccls_islower (void* custom, ase_cint_t c)
{
return ase_islower (c);
}
static ase_bool_t ccls_isalpha (void* custom, ase_cint_t c)
{
return ase_isalpha (c);
}
static ase_bool_t ccls_isdigit (void* custom, ase_cint_t c)
{
return ase_isdigit (c);
}
static ase_bool_t ccls_isxdigit (void* custom, ase_cint_t c)
{
return ase_isxdigit (c);
}
static ase_bool_t ccls_isalnum (void* custom, ase_cint_t c)
{
return ase_isalnum (c);
}
static ase_bool_t ccls_isspace (void* custom, ase_cint_t c)
{
return ase_isspace (c);
}
static ase_bool_t ccls_isprint (void* custom, ase_cint_t c)
{
return ase_isprint (c);
}
static ase_bool_t ccls_isgraph (void* custom, ase_cint_t c)
{
return ase_isgraph (c);
}
static ase_bool_t ccls_iscntrl (void* custom, ase_cint_t c)
{
return ase_iscntrl (c);
}
static ase_bool_t ccls_ispunct (void* custom, ase_cint_t c)
{
return ase_ispunct (c);
}
static ase_cint_t ccls_toupper (void* custom, ase_cint_t c)
{
return ase_toupper (c);
}
static ase_cint_t ccls_tolower (void* custom, ase_cint_t c)
{
return ase_tolower (c);
}
static ase_ccls_t ccls =
{
ccls_isupper,
ccls_islower,
ccls_isalpha,
ccls_isdigit,
ccls_isxdigit,
ccls_isalnum,
ccls_isspace,
ccls_isprint,
ccls_isgraph,
ccls_iscntrl,
ccls_ispunct,
ccls_toupper,
ccls_tolower,
ASE_NULL
};
ase_ccls_t* ase_ccls = &ccls;

View File

@ -2,5 +2,5 @@
AM_CFLAGS = -I$(top_builddir)/include
lib_LTLIBRARIES = libaseutl.la
libaseutl_la_SOURCES = helper.c assert.c ctype.c getopt.c http.c main.c stdio.c
libaseutl_la_SOURCES = assert.c getopt.c http.c main.c stdio.c
libaseutl_la_LDFLAGS = -version-info 1:0:0