1/*-
2 * Copyright (c) 1992, 1993, 1994 Henry Spencer.
3 * Copyright (c) 1992, 1993, 1994
4 *	The Regents of the University of California.  All rights reserved.
5 *
6 * This code is derived from software contributed to Berkeley by
7 * Henry Spencer.
8 *
9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions
11 * are met:
12 * 1. Redistributions of source code must retain the above copyright
13 *    notice, this list of conditions and the following disclaimer.
14 * 2. Redistributions in binary form must reproduce the above copyright
15 *    notice, this list of conditions and the following disclaimer in the
16 *    documentation and/or other materials provided with the distribution.
17 * 4. Neither the name of the University nor the names of its contributors
18 *    may be used to endorse or promote products derived from this software
19 *    without specific prior written permission.
20 *
21 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
22 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24 * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
25 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 *	@(#)cname.h	8.3 (Berkeley) 3/20/94
34 * $FreeBSD: src/lib/libc/regex/cname.h,v 1.4 2007/01/09 00:28:04 imp Exp $
35 */
36
37/* character-name table */
38static const struct cname {
39	const wchar_t *name;
40	wchar_t code;
41} cnames[] = {
42	{L"",				(wchar_t)-1}, /* sentinel */
43	{L"ACK",			L'\006'},
44	{L"BEL",			L'\007'},
45	{L"BS",				L'\010'},
46	{L"CAN",			L'\030'},
47	{L"CR",				L'\015'},
48	{L"DC1",			L'\021'},
49	{L"DC2",			L'\022'},
50	{L"DC3",			L'\023'},
51	{L"DC4",			L'\024'},
52	{L"DEL",			L'\177'},
53	{L"DLE",			L'\020'},
54	{L"EM",				L'\031'},
55	{L"ENQ",			L'\005'},
56	{L"EOT",			L'\004'},
57	{L"ESC",			L'\033'},
58	{L"ETB",			L'\027'},
59	{L"ETX",			L'\003'},
60	{L"FF",				L'\014'},
61	{L"FS",				L'\034'},
62	{L"GS",				L'\035'},
63	{L"HT",				L'\011'},
64	{L"IS1",			L'\037'},
65	{L"IS2",			L'\036'},
66	{L"IS3",			L'\035'},
67	{L"IS4",			L'\034'},
68	{L"LF",				L'\012'},
69	{L"NAK",			L'\025'},
70	{L"NUL",			L'\0'},
71	{L"RS",				L'\036'},
72	{L"SI",				L'\017'},
73	{L"SO",				L'\016'},
74	{L"SOH",			L'\001'},
75	{L"STX",			L'\002'},
76	{L"SUB",			L'\032'},
77	{L"SYN",			L'\026'},
78	{L"US",				L'\037'},
79	{L"VT",				L'\013'},
80	{L"alert",			L'\007'},
81	{L"ampersand",			L'&'},
82	{L"apostrophe",			L'\''},
83	{L"asterisk",			L'*'},
84	{L"backslash",			L'\\'},
85	{L"backspace",			L'\b'},
86	{L"carriage-return",		L'\r'},
87	{L"circumflex",			L'^'},
88	{L"circumflex-accent",		L'^'},
89	{L"colon",			L':'},
90	{L"comma",			L','},
91	{L"commercial-at",		L'@'},
92	{L"dollar-sign",		L'$'},
93	{L"eight",			L'8'},
94	{L"equals-sign",		L'='},
95	{L"exclamation-mark",		L'!'},
96	{L"five",			L'5'},
97	{L"form-feed",			L'\f'},
98	{L"four",			L'4'},
99	{L"full-stop",			L'.'},
100	{L"grave-accent",		L'`'},
101	{L"greater-than-sign",		L'>'},
102	{L"hyphen",			L'-'},
103	{L"hyphen-minus",		L'-'},
104	{L"left-brace",			L'{'},
105	{L"left-curly-bracket",		L'{'},
106	{L"left-parenthesis",		L'('},
107	{L"left-square-bracket",	L'['},
108	{L"less-than-sign",		L'<'},
109	{L"low-line",			L'_'},
110	{L"newline",			L'\n'},
111	{L"nine",			L'9'},
112	{L"number-sign",		L'#'},
113	{L"one",			L'1'},
114	{L"percent-sign",		L'%'},
115	{L"period",			L'.'},
116	{L"plus-sign",			L'+'},
117	{L"question-mark",		L'?'},
118	{L"quotation-mark",		L'"'},
119	{L"reverse-solidus",		L'\\'},
120	{L"right-brace",		L'}'},
121	{L"right-curly-bracket",	L'}'},
122	{L"right-parenthesis",		L')'},
123	{L"right-square-bracket",	L']'},
124	{L"semicolon",			L';'},
125	{L"seven",      		L'7'},
126	{L"six",			L'6'},
127	{L"slash",			L'/'},
128	{L"solidus",			L'/'},
129	{L"space",			L' '},
130	{L"tab",			L'\t'},
131	{L"three",			L'3'},
132	{L"tilde",			L'~'},
133	{L"two",			L'2'},
134	{L"underscore",			L'_'},
135	{L"vertical-line",		L'|'},
136	{L"vertical-tab",		L'\v'},
137	{L"zero",			L'0'},
138};
139
140#define NCNAMES		(sizeof(cnames) / sizeof(*cnames))
141