зеркало из https://github.com/mozilla/gecko-dev.git
94 строки
3.2 KiB
C
94 строки
3.2 KiB
C
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
|
*
|
|
* The contents of this file are subject to the Netscape Public
|
|
* License Version 1.1 (the "License"); you may not use this file
|
|
* except in compliance with the License. You may obtain a copy of
|
|
* the License at http://www.mozilla.org/NPL/
|
|
*
|
|
* Software distributed under the License is distributed on an "AS
|
|
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
|
|
* implied. See the License for the specific language governing
|
|
* rights and limitations under the License.
|
|
*
|
|
* The Original Code is mozilla.org code.
|
|
*
|
|
* The Initial Developer of the Original Code is Netscape
|
|
* Communications Corporation. Portions created by Netscape are
|
|
* Copyright (C) 1998 Netscape Communications Corporation. All
|
|
* Rights Reserved.
|
|
*
|
|
* Contributor(s):
|
|
*/
|
|
/*
|
|
* DO NOT EDIT THIS DOCUMENT MANUALLY !!!
|
|
* THIS FILE IS AUTOMATICALLY GENERATED BY THE TOOLS UNDER
|
|
* mozilla/intl/chardet/tools/
|
|
* Please contact ftang@netscape.com or mozilla-i18n@mozilla.org
|
|
* if you have any question. Thanks
|
|
*/
|
|
#include "nsVerifier.h"
|
|
static PRUint32 EUCTW_cls [ 256 / 8 ] = {
|
|
PCK4BITS(0,2,2,2,2,2,2,2), // 00 - 07
|
|
PCK4BITS(2,2,2,2,2,2,0,0), // 08 - 0f
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 10 - 17
|
|
PCK4BITS(2,2,2,0,2,2,2,2), // 18 - 1f
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 20 - 27
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 28 - 2f
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 30 - 37
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 38 - 3f
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 40 - 47
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 48 - 4f
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 50 - 57
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 58 - 5f
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 60 - 67
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 68 - 6f
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 70 - 77
|
|
PCK4BITS(2,2,2,2,2,2,2,2), // 78 - 7f
|
|
PCK4BITS(0,0,0,0,0,0,0,0), // 80 - 87
|
|
PCK4BITS(0,0,0,0,0,0,6,0), // 88 - 8f
|
|
PCK4BITS(0,0,0,0,0,0,0,0), // 90 - 97
|
|
PCK4BITS(0,0,0,0,0,0,0,0), // 98 - 9f
|
|
PCK4BITS(0,3,4,4,4,4,4,4), // a0 - a7
|
|
PCK4BITS(5,5,1,1,1,1,1,1), // a8 - af
|
|
PCK4BITS(1,1,1,1,1,1,1,1), // b0 - b7
|
|
PCK4BITS(1,1,1,1,1,1,1,1), // b8 - bf
|
|
PCK4BITS(1,1,3,1,3,3,3,3), // c0 - c7
|
|
PCK4BITS(3,3,3,3,3,3,3,3), // c8 - cf
|
|
PCK4BITS(3,3,3,3,3,3,3,3), // d0 - d7
|
|
PCK4BITS(3,3,3,3,3,3,3,3), // d8 - df
|
|
PCK4BITS(3,3,3,3,3,3,3,3), // e0 - e7
|
|
PCK4BITS(3,3,3,3,3,3,3,3), // e8 - ef
|
|
PCK4BITS(3,3,3,3,3,3,3,3), // f0 - f7
|
|
PCK4BITS(3,3,3,3,3,3,3,0) // f8 - ff
|
|
};
|
|
|
|
|
|
static PRUint32 EUCTW_st [ 6] = {
|
|
PCK4BITS(eError,eError,eStart, 3, 3, 3, 4,eError),//00-07
|
|
PCK4BITS(eError,eError,eError,eError,eError,eError,eItsMe,eItsMe),//08-0f
|
|
PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eError,eStart,eError),//10-17
|
|
PCK4BITS(eStart,eStart,eStart,eError,eError,eError,eError,eError),//18-1f
|
|
PCK4BITS( 5,eError,eError,eError,eStart,eError,eStart,eStart),//20-27
|
|
PCK4BITS(eStart,eError,eStart,eStart,eStart,eStart,eStart,eStart) //28-2f
|
|
};
|
|
|
|
|
|
static nsVerifier nsEUCTWVerifier = {
|
|
"x-euc-tw",
|
|
{
|
|
eIdxSft4bits,
|
|
eSftMsk4bits,
|
|
eBitSft4bits,
|
|
eUnitMsk4bits,
|
|
EUCTW_cls
|
|
},
|
|
7,
|
|
{
|
|
eIdxSft4bits,
|
|
eSftMsk4bits,
|
|
eBitSft4bits,
|
|
eUnitMsk4bits,
|
|
EUCTW_st
|
|
}
|
|
};
|