Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/perseant-stdc-iso10646]: src/lib/libc Add missing files from last commit:



details:   https://anonhg.NetBSD.org/src/rev/668a3d0fdb90
branches:  perseant-stdc-iso10646
changeset: 850676:668a3d0fdb90
user:      perseant <perseant%NetBSD.org@localhost>
date:      Sun Jul 23 18:51:21 2017 +0000

description:
Add missing files from last commit:

Move Unicode <-> ku/ten mapping into the individual codec modules.
Mapping is based on existing iconv data for single-byte encodings,
and included for several, but not all, multibyte encodings.

diffstat:

 lib/libc/citrus/citrus_u2k_template.h |  25 +++++++++++++++++++++++++
 lib/libc/iconv/iconv.c                |   5 +++--
 2 files changed, 28 insertions(+), 2 deletions(-)

diffs (55 lines):

diff -r 5f239afcfdc3 -r 668a3d0fdb90 lib/libc/citrus/citrus_u2k_template.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/lib/libc/citrus/citrus_u2k_template.h     Sun Jul 23 18:51:21 2017 +0000
@@ -0,0 +1,25 @@
+static __inline int
+/*ARGSUSED*/
+_FUNCNAME(ucs2kt)(_ENCODING_INFO * __restrict ei,
+                 wchar_kuten_t * __restrict ktp, wchar_ucs4_t wc)
+{
+
+       _DIAGASSERT(ktp != NULL);
+
+       *ktp = wc;
+
+       return 0;
+}
+
+static __inline int
+/*ARGSUSED*/
+_FUNCNAME(kt2ucs)(_ENCODING_INFO * __restrict ei,
+                 wchar_ucs4_t * __restrict up, wchar_kuten_t kt)
+{
+
+       _DIAGASSERT(up != NULL);
+       
+       *up = kt;
+
+       return 0;
+}
diff -r 5f239afcfdc3 -r 668a3d0fdb90 lib/libc/iconv/iconv.c
--- a/lib/libc/iconv/iconv.c    Fri Jul 21 20:22:29 2017 +0000
+++ b/lib/libc/iconv/iconv.c    Sun Jul 23 18:51:21 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: iconv.c,v 1.13 2012/01/20 16:31:29 joerg Exp $ */
+/*     $NetBSD: iconv.c,v 1.13.34.1 2017/07/23 18:51:21 perseant Exp $ */
 
 /*-
  * Copyright (c)2003 Citrus Project,
@@ -28,7 +28,7 @@
 
 #include <sys/cdefs.h>
 #if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: iconv.c,v 1.13 2012/01/20 16:31:29 joerg Exp $");
+__RCSID("$NetBSD: iconv.c,v 1.13.34.1 2017/07/23 18:51:21 perseant Exp $");
 #endif /* LIBC_SCCS and not lint */
 
 #include "namespace.h"
@@ -36,6 +36,7 @@
 #include <errno.h>
 #include <paths.h>
 #include <sys/queue.h>
+#include <wchar.h>
 
 #include <iconv.h>
 



Home | Main Index | Thread Index | Old Index