3 * This file and its contents are supplied under the terms of the
4 * Common Development and Distribution License ("CDDL"), version 1.0.
5 * You may only use this file in accordance with the terms of version
8 * A full copy of the text of the CDDL should have accompanied this
9 * source. A copy of the CDDL is also available via the Internet at
10 * http://www.illumos.org/license/CDDL.
14 * Copyright 2011 Nexenta Systems, Inc. All rights reserved.
18 * POSIX iconv charmap grammar.
30 char mbs
[MB_LEN_MAX
+ 2]; /* NB: [0] is length! */
51 %token T_WIDTH_DEFAULT
55 %token
<token
> T_SYMBOL
59 goal
: setting_list charmap
63 string : T_QUOTE charlist T_QUOTE
67 charlist
: charlist T_CHAR
71 setting_list
: setting_list setting
75 setting
: T_COM_CHAR T_CHAR T_NL
79 | T_ESC_CHAR T_CHAR T_NL
83 | T_MB_CUR_MAX T_NUMBER T_NL
87 | T_MB_CUR_MIN T_NUMBER T_NL
91 | T_CODE_SET T_NAME T_NL
95 | T_CODE_SET
string T_NL
101 charmap
: T_CHARMAP T_NL charmap_list T_END T_CHARMAP T_NL
103 charmap_list
: charmap_list charmap_entry
107 charmap_entry
: T_SYMBOL T_CHAR
112 | T_SYMBOL T_ELLIPSIS T_SYMBOL T_CHAR
114 add_charmap_range
($1, $3, $4);