Ruby  1.9.3p551(2014-11-13revision48407)
ascii.c
Go to the documentation of this file.
1 /**********************************************************************
2  ascii.c - Oniguruma (regular expression library)
3 **********************************************************************/
4 /*-
5  * Copyright (c) 2002-2006 K.Kosako <sndgk393 AT ybb DOT ne DOT jp>
6  * All rights reserved.
7  *
8  * Redistribution and use in source and binary forms, with or without
9  * modification, are permitted provided that the following conditions
10  * are met:
11  * 1. Redistributions of source code must retain the above copyright
12  * notice, this list of conditions and the following disclaimer.
13  * 2. Redistributions in binary form must reproduce the above copyright
14  * notice, this list of conditions and the following disclaimer in the
15  * documentation and/or other materials provided with the distribution.
16  *
17  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20  * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
21  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27  * SUCH DAMAGE.
28  */
29 
30 #include "regenc.h"
31 
32 OnigEncodingDefine(ascii, ASCII) = {
34  "ASCII-8BIT",/* name */
35  1, /* max byte length */
36  1, /* min byte length */
49 };
50 ENC_ALIAS("BINARY", "ASCII-8BIT")
51 ENC_REPLICATE("IBM437", "ASCII-8BIT")
52 ENC_ALIAS("CP437", "IBM437")
53 ENC_REPLICATE("IBM737", "ASCII-8BIT")
54 ENC_ALIAS("CP737", "IBM737")
55 ENC_REPLICATE("IBM775", "ASCII-8BIT")
56 ENC_ALIAS("CP775", "IBM775")
57 ENC_REPLICATE("CP850", "ASCII-8BIT")
58 ENC_ALIAS("IBM850", "CP850")
59 ENC_REPLICATE("IBM852", "ASCII-8BIT")
60 ENC_REPLICATE("CP852", "IBM852")
61 ENC_REPLICATE("IBM855", "ASCII-8BIT")
62 ENC_REPLICATE("CP855", "IBM855")
63 ENC_REPLICATE("IBM857", "ASCII-8BIT")
64 ENC_ALIAS("CP857", "IBM857")
65 ENC_REPLICATE("IBM860", "ASCII-8BIT")
66 ENC_ALIAS("CP860", "IBM860")
67 ENC_REPLICATE("IBM861", "ASCII-8BIT")
68 ENC_ALIAS("CP861", "IBM861")
69 ENC_REPLICATE("IBM862", "ASCII-8BIT")
70 ENC_ALIAS("CP862", "IBM862")
71 ENC_REPLICATE("IBM863", "ASCII-8BIT")
72 ENC_ALIAS("CP863", "IBM863")
73 ENC_REPLICATE("IBM864", "ASCII-8BIT")
74 ENC_ALIAS("CP864", "IBM864")
75 ENC_REPLICATE("IBM865", "ASCII-8BIT")
76 ENC_ALIAS("CP865", "IBM865")
77 ENC_REPLICATE("IBM866", "ASCII-8BIT")
78 ENC_ALIAS("CP866", "IBM866")
79 ENC_REPLICATE("IBM869", "ASCII-8BIT")
80 ENC_ALIAS("CP869", "IBM869")
81 ENC_REPLICATE("Windows-1258", "ASCII-8BIT")
82 ENC_ALIAS("CP1258", "Windows-1258")
83 ENC_REPLICATE("GB1988", "ASCII-8BIT")
84 ENC_REPLICATE("macCentEuro", "ASCII-8BIT")
85 ENC_REPLICATE("macCroatian", "ASCII-8BIT")
86 ENC_REPLICATE("macCyrillic", "ASCII-8BIT")
87 ENC_REPLICATE("macGreek", "ASCII-8BIT")
88 ENC_REPLICATE("macIceland", "ASCII-8BIT")
89 ENC_REPLICATE("macRoman", "ASCII-8BIT")
90 ENC_REPLICATE("macRomania", "ASCII-8BIT")
91 ENC_REPLICATE("macThai", "ASCII-8BIT")
92 ENC_REPLICATE("macTurkish", "ASCII-8BIT")
93 ENC_REPLICATE("macUkraine", "ASCII-8BIT")
#define OnigEncodingDefine(f, n)
int onigenc_always_true_is_allowed_reverse_match(const UChar *s ARG_UNUSED, const UChar *end ARG_UNUSED, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:649
OnigCodePoint onigenc_single_byte_mbc_to_code(const UChar *p, const UChar *end ARG_UNUSED, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:619
int onigenc_ascii_is_code_ctype(OnigCodePoint code, unsigned int ctype, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:663
int onigenc_ascii_apply_all_case_fold(OnigCaseFoldType flag ARG_UNUSED, OnigApplyAllCaseFoldFunc f, void *arg, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:409
#define ENC_ALIAS(name, orig)
Definition: encdb.c:18
#define BIT(c, idx)
Definition: ripper.c:12300
Definition: nkf.c:87
int onigenc_single_byte_code_to_mbclen(OnigCodePoint code ARG_UNUSED, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:626
UChar * onigenc_single_byte_left_adjust_char_head(const UChar *start ARG_UNUSED, const UChar *s, const UChar *end, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:641
int onigenc_is_mbc_newline_0x0a(const UChar *p, const UChar *end, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:580
int onigenc_single_byte_mbc_enc_len(const UChar *p ARG_UNUSED, const UChar *e ARG_UNUSED, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:612
int onigenc_not_support_get_ctype_code_range(OnigCtype ctype, OnigCodePoint *sb_out, const OnigCodePoint *ranges[], OnigEncoding enc)
Definition: regenc.c:572
int onigenc_ascii_get_case_fold_codes_by_str(OnigCaseFoldType flag ARG_UNUSED, const OnigUChar *p, const OnigUChar *end ARG_UNUSED, OnigCaseFoldCodeItem items[], OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:432
#define ENC_REPLICATE(name, orig)
Definition: encdb.c:17
int onigenc_single_byte_code_to_mbc(OnigCodePoint code, UChar *buf, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:632
int onigenc_minimum_property_name_to_ctype(OnigEncoding enc, UChar *p, UChar *end)
Definition: regenc.c:790
int onigenc_ascii_mbc_case_fold(OnigCaseFoldType flag ARG_UNUSED, const UChar **p, const UChar *end, UChar *lower, OnigEncoding enc ARG_UNUSED)
Definition: regenc.c:590