xis.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 1996-2022 The Squid Software Foundation and contributors
3 *
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
7 */
8
9#ifndef _SQUID_COMPAT_XIS_H
10#define _SQUID_COMPAT_XIS_H
11
12#if HAVE_CTYPE_H
13#include <ctype.h>
14#endif
15
16#if __cplusplus
17#define xisspace(x) isspace(static_cast<unsigned char>(x))
18#define xtoupper(x) toupper(static_cast<unsigned char>(x))
19#define xtolower(x) tolower(static_cast<unsigned char>(x))
20#define xisdigit(x) isdigit(static_cast<unsigned char>(x))
21#define xisascii(x) isascii(static_cast<unsigned char>(x))
22#define xislower(x) islower(static_cast<unsigned char>(x))
23#define xisalpha(x) isalpha(static_cast<unsigned char>(x))
24#define xisprint(x) isprint(static_cast<unsigned char>(x))
25#define xisalnum(x) isalnum(static_cast<unsigned char>(x))
26#define xiscntrl(x) iscntrl(static_cast<unsigned char>(x))
27#define xispunct(x) ispunct(static_cast<unsigned char>(x))
28#define xisupper(x) isupper(static_cast<unsigned char>(x))
29#define xisxdigit(x) isxdigit(static_cast<unsigned char>(x))
30#define xisgraph(x) isgraph(static_cast<unsigned char>(x))
31
32#else /* ! __cplusplus */
33#define xisspace(x) isspace((unsigned char)x)
34#define xtoupper(x) toupper((unsigned char)x)
35#define xtolower(x) tolower((unsigned char)x)
36#define xisdigit(x) isdigit((unsigned char)x)
37#define xisascii(x) isascii((unsigned char)x)
38#define xislower(x) islower((unsigned char)x)
39#define xisalpha(x) isalpha((unsigned char)x)
40#define xisprint(x) isprint((unsigned char)x)
41#define xisalnum(x) isalnum((unsigned char)x)
42#define xiscntrl(x) iscntrl((unsigned char)x)
43#define xispunct(x) ispunct((unsigned char)x)
44#define xisupper(x) isupper((unsigned char)x)
45#define xisxdigit(x) isxdigit((unsigned char)x)
46#define xisgraph(x) isgraph((unsigned char)x)
47#endif
48
49#endif /* _SQUID_COMPAT_XIS_H */
50

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors