128 bracketleft_char_entry, /* 6 */
129 bracketright_char_entry, /* 7 */
130 colon_char_entry, /* 8 */
131 dollar_char_entry, /* 9 */
132 doublequote_char_entry, /* 10 */
133 equal_char_entry, /* 11 */
134 exclam_char_entry, /* 12 */
135 greater_char_entry, /* 13 */
136 hat_char_entry, /* 14 */
137 hyphen_char_entry, /* 15 */
138 less_char_entry, /* 16 */
139 newline_char_entry, /* 17 */
140 numbersign_char_entry, /* 18 */
141 parenleft_char_entry, /* 19 */
142 parenright_char_entry, /* 20 */
143 percent_char_entry, /* 21 */
144 plus_char_entry, /* 22 */
145 question_char_entry, /* 23 */
146 quote_char_entry, /* 24 */
147 semicolon_char_entry, /* 25 */
148 #ifdef SGE_SUPPORT
149 space_char_entry, /* 26 */
150 tab_char_entry, /* 27 */
151 no_semantics_entry /* 28 */
152 #else
153 no_semantics_entry /* 26 */
154 #endif /* SGE_SUPPORT */
155 };
156
157 /*
158 * CHAR_SEMANTICS_ENTRIES should be the number of entries above.
159 * The last entry in char_semantics[] should be blank.
160 */
161 #ifdef SGE_SUPPORT
162 #define CHAR_SEMANTICS_ENTRIES 29
163 /*
164 #define CHAR_SEMANTICS_STRING "&*@`\\|[]:$=!>-\n#()%+?;^<'\" \t"
165 */
166 #else
167 #define CHAR_SEMANTICS_ENTRIES 27
168 /*
169 #define CHAR_SEMANTICS_STRING "&*@`\\|[]:$=!>-\n#()%+?;^<'\""
170 */
171 #endif /* SGE_SUPPORT */
172
173 /*
174 * Some utility macros
175 */
176 #define ALLOC(x) ((struct _##x *)getmem(sizeof (struct _##x)))
177 #define ALLOC_WC(x) ((wchar_t *)getmem((x) * SIZEOFWCHAR_T))
178 #define FIND_LENGTH -1
179 #define GETNAME(a,b) getname_fn((a), (b), false)
180 #define IS_EQUAL(a,b) (!strcmp((a), (b)))
181 #define IS_EQUALN(a,b,n) (!strncmp((a), (b), (n)))
182 #define IS_WEQUAL(a,b) (!wscmp((a), (b)))
183 #define IS_WEQUALN(a,b,n) (!wsncmp((a), (b), (n)))
184 #define MBLEN(a) mblen((a), MB_LEN_MAX)
185 #define MBSTOWCS(a,b) (void) mbstowcs_with_check((a), (b), MAXPATHLEN)
186 #define MBTOWC(a,b) mbtowc((a), (b), MB_LEN_MAX)
187 #define SIZEOFWCHAR_T (sizeof (wchar_t))
188 #define VSIZEOF(v) (sizeof (v) / sizeof ((v)[0]))
189 #define WCSTOMBS(a,b) (void) wcstombs((a), (b), (MAXPATHLEN * MB_LEN_MAX))
190 #define WCTOMB(a,b) (void) wctomb((a), (b))
191 #define HASH(v, c) (v = (v)*31 + (unsigned int)(c))
|
128 bracketleft_char_entry, /* 6 */
129 bracketright_char_entry, /* 7 */
130 colon_char_entry, /* 8 */
131 dollar_char_entry, /* 9 */
132 doublequote_char_entry, /* 10 */
133 equal_char_entry, /* 11 */
134 exclam_char_entry, /* 12 */
135 greater_char_entry, /* 13 */
136 hat_char_entry, /* 14 */
137 hyphen_char_entry, /* 15 */
138 less_char_entry, /* 16 */
139 newline_char_entry, /* 17 */
140 numbersign_char_entry, /* 18 */
141 parenleft_char_entry, /* 19 */
142 parenright_char_entry, /* 20 */
143 percent_char_entry, /* 21 */
144 plus_char_entry, /* 22 */
145 question_char_entry, /* 23 */
146 quote_char_entry, /* 24 */
147 semicolon_char_entry, /* 25 */
148 no_semantics_entry /* 26 */
149 };
150
151 /*
152 * CHAR_SEMANTICS_ENTRIES should be the number of entries above.
153 * The last entry in char_semantics[] should be blank.
154 */
155 #define CHAR_SEMANTICS_ENTRIES 27
156 /*
157 #define CHAR_SEMANTICS_STRING "&*@`\\|[]:$=!>-\n#()%+?;^<'\""
158 */
159
160 /*
161 * Some utility macros
162 */
163 #define ALLOC(x) ((struct _##x *)getmem(sizeof (struct _##x)))
164 #define ALLOC_WC(x) ((wchar_t *)getmem((x) * SIZEOFWCHAR_T))
165 #define FIND_LENGTH -1
166 #define GETNAME(a,b) getname_fn((a), (b), false)
167 #define IS_EQUAL(a,b) (!strcmp((a), (b)))
168 #define IS_EQUALN(a,b,n) (!strncmp((a), (b), (n)))
169 #define IS_WEQUAL(a,b) (!wscmp((a), (b)))
170 #define IS_WEQUALN(a,b,n) (!wsncmp((a), (b), (n)))
171 #define MBLEN(a) mblen((a), MB_LEN_MAX)
172 #define MBSTOWCS(a,b) (void) mbstowcs_with_check((a), (b), MAXPATHLEN)
173 #define MBTOWC(a,b) mbtowc((a), (b), MB_LEN_MAX)
174 #define SIZEOFWCHAR_T (sizeof (wchar_t))
175 #define VSIZEOF(v) (sizeof (v) / sizeof ((v)[0]))
176 #define WCSTOMBS(a,b) (void) wcstombs((a), (b), (MAXPATHLEN * MB_LEN_MAX))
177 #define WCTOMB(a,b) (void) wctomb((a), (b))
178 #define HASH(v, c) (v = (v)*31 + (unsigned int)(c))
|