summaryrefslogtreecommitdiff
path: root/bin/csh/char.h
diff options
context:
space:
mode:
authorChristian Weisgerber <naddy@cvs.openbsd.org>2015-10-26 15:01:16 +0000
committerChristian Weisgerber <naddy@cvs.openbsd.org>2015-10-26 15:01:16 +0000
commit64dc4c6ed3e987e79a9d67a4b96e328bfd57b64c (patch)
tree94f17d7c3c9b0d217f1ee688e4d12df0c4823d02 /bin/csh/char.h
parent3449fa5141a1d9cec121c1da43ee347774dc1c59 (diff)
unifdef BUILTIN (unused), NLS (always set), SHORT_STRINGS (always set)
and remove a few unused defines; no binary changes; ok tedu@ zhuk@
Diffstat (limited to 'bin/csh/char.h')
-rw-r--r--bin/csh/char.h24
1 files changed, 1 insertions, 23 deletions
diff --git a/bin/csh/char.h b/bin/csh/char.h
index dcfad3ea953..c8164f24f3e 100644
--- a/bin/csh/char.h
+++ b/bin/csh/char.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: char.h,v 1.4 2003/06/02 23:32:06 millert Exp $ */
+/* $OpenBSD: char.h,v 1.5 2015/10/26 15:01:15 naddy Exp $ */
/* $NetBSD: char.h,v 1.6 1995/03/21 09:02:29 cgd Exp $ */
/*-
@@ -36,11 +36,6 @@
extern unsigned short _cmap[];
-#ifndef NLS
-extern unsigned char _cmap_lower[], _cmap_upper[];
-
-#endif
-
#define _QF 0x0001 /* '" (Forward quotes) */
#define _QB 0x0002 /* ` (Backquote) */
#define _SP 0x0004 /* space and tab */
@@ -61,14 +56,10 @@ extern unsigned char _cmap_lower[], _cmap_upper[];
(((c) & QUOTE) ? 0 : (_cmap[(unsigned char)(c)] & (bits)))
#define isglob(c) cmap(c, _GLOB)
-#define isspc(c) cmap(c, _SP)
-#define ismeta(c) cmap(c, _META)
-#define iscmdmeta(c) cmap(c, _CMD)
#define letter(c) (((c) & QUOTE) ? 0 : \
(isalpha((unsigned char) (c)) || (c) == '_'))
#define alnum(c) (((c) & QUOTE) ? 0 : \
(isalnum((unsigned char) (c)) || (c) == '_'))
-#ifdef NLS
#define Isspace(c) (((c) & QUOTE) ? 0 : isspace((unsigned char) (c)))
#define Isdigit(c) (((c) & QUOTE) ? 0 : isdigit((unsigned char) (c)))
#define Isalpha(c) (((c) & QUOTE) ? 0 : isalpha((unsigned char) (c)))
@@ -80,16 +71,3 @@ extern unsigned char _cmap_lower[], _cmap_upper[];
#define Isalnum(c) (((c) & QUOTE) ? 0 : isalnum((unsigned char) (c)))
#define Iscntrl(c) (((c) & QUOTE) ? 0 : iscntrl((unsigned char) (c)))
#define Isprint(c) (((c) & QUOTE) ? 0 : isprint((unsigned char) (c)))
-#else
-#define Isspace(c) cmap(c, _SP|_NL)
-#define Isdigit(c) cmap(c, _DIG)
-#define Isalpha(c) (cmap(c,_LET) && !(((c) & META) && AsciiOnly))
-#define Islower(c) (cmap(c,_LOW) && !(((c) & META) && AsciiOnly))
-#define Isupper(c) (cmap(c, _UP) && !(((c) & META) && AsciiOnly))
-#define Tolower(c) (_cmap_lower[(unsigned char)(c)])
-#define Toupper(c) (_cmap_upper[(unsigned char)(c)])
-#define Isxdigit(c) cmap(c, _XD)
-#define Isalnum(c) (cmap(c, _DIG|_LET) && !(((c) & META) && AsciiOnly))
-#define Iscntrl(c) (cmap(c,_CTR) && !(((c) & META) && AsciiOnly))
-#define Isprint(c) (!cmap(c,_CTR) && !(((c) & META) && AsciiOnly))
-#endif