Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libc/locale _runetype_from_ctype is unused
details: https://anonhg.NetBSD.org/src/rev/8273cedaf132
branches: trunk
changeset: 772852:8273cedaf132
user: joerg <joerg%NetBSD.org@localhost>
date: Wed Jan 18 14:22:27 2012 +0000
description:
_runetype_from_ctype is unused
diffstat:
lib/libc/locale/runetype_misc.h | 50 +----------------------------------------
1 files changed, 1 insertions(+), 49 deletions(-)
diffs (62 lines):
diff -r 889203d096d9 -r 8273cedaf132 lib/libc/locale/runetype_misc.h
--- a/lib/libc/locale/runetype_misc.h Wed Jan 18 12:39:45 2012 +0000
+++ b/lib/libc/locale/runetype_misc.h Wed Jan 18 14:22:27 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: runetype_misc.h,v 1.2 2010/12/14 02:28:57 joerg Exp $ */
+/* $NetBSD: runetype_misc.h,v 1.3 2012/01/18 14:22:27 joerg Exp $ */
/*-
* Copyright (c) 1993
@@ -79,52 +79,4 @@
return ret;
}
-static __inline _RuneType
-_runetype_from_ctype(int bits, int ch)
-{
- _RuneType ret;
-
- /*
- * TWEAKS!
- * - old locale file declarations do not have proper _B
- * in many cases.
- * - isprint() declaration in ctype.h incorrectly uses _B.
- * _B means "isprint but !isgraph", not "isblank" with the
- * declaration.
- * - _X and _RUNETYPE_X have negligible difference in meaning.
- * - we don't set digit value, fearing that it would be
- * too much of hardcoding. we may need to revisit it.
- */
-
- ret = (_RuneType)0;
- if (bits & _CTYPE_U)
- ret |= _RUNETYPE_U;
- if (bits & _CTYPE_L)
- ret |= _RUNETYPE_L;
- if (bits & _CTYPE_N)
- ret |= _RUNETYPE_D;
- if (bits & _CTYPE_S)
- ret |= _RUNETYPE_S;
- if (bits & _CTYPE_P)
- ret |= _RUNETYPE_P;
- if (bits & _CTYPE_C)
- ret |= _RUNETYPE_C;
- /* derived flag bits, duplicate of ctype.h */
- if (bits & (_CTYPE_U|_CTYPE_L))
- ret |= _RUNETYPE_A;
- if (bits & (_CTYPE_N|_CTYPE_X))
- ret |= _RUNETYPE_X;
- if (bits & (_CTYPE_P|_CTYPE_U|_CTYPE_L|_CTYPE_N))
- ret |= _RUNETYPE_G;
- /* we don't really trust _B in the file. see above. */
- if (bits & _CTYPE_B)
- ret |= _RUNETYPE_B;
- if ((bits & (_CTYPE_P|_CTYPE_U|_CTYPE_L|_CTYPE_N|_CTYPE_B)) ||
- ch == ' ')
- ret |= (_RUNETYPE_R | _RUNETYPE_SW1);
- if (ch == ' ' || ch == '\t')
- ret |= _RUNETYPE_B;
- return ret;
-}
-
#endif /* !_RUNETYPE_MISC_H_ */
Home |
Main Index |
Thread Index |
Old Index