1 /* Normalization of UTF-16 strings. 2 Copyright (C) 2009-2018 Free Software Foundation, Inc. 3 Written by Bruno Haible <bruno@clisp.org>, 2009. 4 5 This program is free software: you can redistribute it and/or 6 modify it under the terms of either: 7 8 * the GNU Lesser General Public License as published by the Free 9 Software Foundation; either version 3 of the License, or (at your 10 option) any later version. 11 12 or 13 14 * the GNU General Public License as published by the Free 15 Software Foundation; either version 2 of the License, or (at your 16 option) any later version. 17 18 or both in parallel, as here. 19 This program is distributed in the hope that it will be useful, 20 but WITHOUT ANY WARRANTY; without even the implied warranty of 21 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 22 Lesser General Public License for more details. 23 24 You should have received a copy of the GNU Lesser General Public License 25 along with this program. If not, see <https://www.gnu.org/licenses/>. */ 26 27 #include <config.h> 28 29 /* Specification. */ 30 #include "uninorm.h" 31 32 #include <errno.h> 33 #include <stddef.h> 34 #include <stdlib.h> 35 #include <string.h> 36 37 #include "unistr.h" 38 #include "unictype.h" 39 #include "normalize-internal.h" 40 #include "decompose-internal.h" 41 42 #define FUNC u16_normalize 43 #define UNIT uint16_t 44 #define U_MBTOUC_UNSAFE u16_mbtouc_unsafe 45 #define U_UCTOMB u16_uctomb 46 #define U_CPY u16_cpy 47 #include "u-normalize-internal.h" 48