1pub const ONIGURUMA_VERSION_MAJOR: u32 = 6;
4pub const ONIGURUMA_VERSION_MINOR: u32 = 9;
5pub const ONIGURUMA_VERSION_TEENY: u32 = 8;
6pub const ONIGURUMA_VERSION_INT: u32 = 60908;
7pub const ONIGENC_CASE_FOLD_ASCII_ONLY: u32 = 1;
8pub const ONIGENC_CASE_FOLD_TURKISH_AZERI: u32 = 1048576;
9pub const INTERNAL_ONIGENC_CASE_FOLD_MULTI_CHAR: u32 = 1073741824;
10pub const ONIGENC_CASE_FOLD_MIN: u32 = 1073741824;
11pub const ONIGENC_MAX_COMP_CASE_FOLD_CODE_LEN: u32 = 3;
12pub const ONIGENC_GET_CASE_FOLD_CODES_MAX_NUM: u32 = 13;
13pub const ONIGENC_CODE_TO_MBC_MAXLEN: u32 = 7;
14pub const ONIGENC_MBC_CASE_FOLD_MAXLEN: u32 = 18;
15pub const ONIG_NREGION: u32 = 10;
16pub const ONIG_MAX_CAPTURE_NUM: u32 = 2147483647;
17pub const ONIG_MAX_BACKREF_NUM: u32 = 1000;
18pub const ONIG_MAX_REPEAT_NUM: u32 = 100000;
19pub const ONIG_MAX_MULTI_BYTE_RANGES_NUM: u32 = 10000;
20pub const ONIG_MAX_ERROR_MESSAGE_LEN: u32 = 90;
21pub const ONIG_OPTION_NONE: u32 = 0;
22pub const ONIG_OPTION_IGNORECASE: u32 = 1;
23pub const ONIG_OPTION_EXTEND: u32 = 2;
24pub const ONIG_OPTION_MULTILINE: u32 = 4;
25pub const ONIG_OPTION_SINGLELINE: u32 = 8;
26pub const ONIG_OPTION_FIND_LONGEST: u32 = 16;
27pub const ONIG_OPTION_FIND_NOT_EMPTY: u32 = 32;
28pub const ONIG_OPTION_NEGATE_SINGLELINE: u32 = 64;
29pub const ONIG_OPTION_DONT_CAPTURE_GROUP: u32 = 128;
30pub const ONIG_OPTION_CAPTURE_GROUP: u32 = 256;
31pub const ONIG_OPTION_NOTBOL: u32 = 512;
32pub const ONIG_OPTION_NOTEOL: u32 = 1024;
33pub const ONIG_OPTION_POSIX_REGION: u32 = 2048;
34pub const ONIG_OPTION_CHECK_VALIDITY_OF_STRING: u32 = 4096;
35pub const ONIG_OPTION_IGNORECASE_IS_ASCII: u32 = 32768;
36pub const ONIG_OPTION_WORD_IS_ASCII: u32 = 65536;
37pub const ONIG_OPTION_DIGIT_IS_ASCII: u32 = 131072;
38pub const ONIG_OPTION_SPACE_IS_ASCII: u32 = 262144;
39pub const ONIG_OPTION_POSIX_IS_ASCII: u32 = 524288;
40pub const ONIG_OPTION_TEXT_SEGMENT_EXTENDED_GRAPHEME_CLUSTER: u32 = 1048576;
41pub const ONIG_OPTION_TEXT_SEGMENT_WORD: u32 = 2097152;
42pub const ONIG_OPTION_NOT_BEGIN_STRING: u32 = 4194304;
43pub const ONIG_OPTION_NOT_END_STRING: u32 = 8388608;
44pub const ONIG_OPTION_NOT_BEGIN_POSITION: u32 = 16777216;
45pub const ONIG_OPTION_CALLBACK_EACH_MATCH: u32 = 33554432;
46pub const ONIG_OPTION_MATCH_WHOLE_STRING: u32 = 67108864;
47pub const ONIG_OPTION_MAXBIT: u32 = 67108864;
48pub const ONIG_SYN_OP_VARIABLE_META_CHARACTERS: u32 = 1;
49pub const ONIG_SYN_OP_DOT_ANYCHAR: u32 = 2;
50pub const ONIG_SYN_OP_ASTERISK_ZERO_INF: u32 = 4;
51pub const ONIG_SYN_OP_ESC_ASTERISK_ZERO_INF: u32 = 8;
52pub const ONIG_SYN_OP_PLUS_ONE_INF: u32 = 16;
53pub const ONIG_SYN_OP_ESC_PLUS_ONE_INF: u32 = 32;
54pub const ONIG_SYN_OP_QMARK_ZERO_ONE: u32 = 64;
55pub const ONIG_SYN_OP_ESC_QMARK_ZERO_ONE: u32 = 128;
56pub const ONIG_SYN_OP_BRACE_INTERVAL: u32 = 256;
57pub const ONIG_SYN_OP_ESC_BRACE_INTERVAL: u32 = 512;
58pub const ONIG_SYN_OP_VBAR_ALT: u32 = 1024;
59pub const ONIG_SYN_OP_ESC_VBAR_ALT: u32 = 2048;
60pub const ONIG_SYN_OP_LPAREN_SUBEXP: u32 = 4096;
61pub const ONIG_SYN_OP_ESC_LPAREN_SUBEXP: u32 = 8192;
62pub const ONIG_SYN_OP_ESC_AZ_BUF_ANCHOR: u32 = 16384;
63pub const ONIG_SYN_OP_ESC_CAPITAL_G_BEGIN_ANCHOR: u32 = 32768;
64pub const ONIG_SYN_OP_DECIMAL_BACKREF: u32 = 65536;
65pub const ONIG_SYN_OP_BRACKET_CC: u32 = 131072;
66pub const ONIG_SYN_OP_ESC_W_WORD: u32 = 262144;
67pub const ONIG_SYN_OP_ESC_LTGT_WORD_BEGIN_END: u32 = 524288;
68pub const ONIG_SYN_OP_ESC_B_WORD_BOUND: u32 = 1048576;
69pub const ONIG_SYN_OP_ESC_S_WHITE_SPACE: u32 = 2097152;
70pub const ONIG_SYN_OP_ESC_D_DIGIT: u32 = 4194304;
71pub const ONIG_SYN_OP_LINE_ANCHOR: u32 = 8388608;
72pub const ONIG_SYN_OP_POSIX_BRACKET: u32 = 16777216;
73pub const ONIG_SYN_OP_QMARK_NON_GREEDY: u32 = 33554432;
74pub const ONIG_SYN_OP_ESC_CONTROL_CHARS: u32 = 67108864;
75pub const ONIG_SYN_OP_ESC_C_CONTROL: u32 = 134217728;
76pub const ONIG_SYN_OP_ESC_OCTAL3: u32 = 268435456;
77pub const ONIG_SYN_OP_ESC_X_HEX2: u32 = 536870912;
78pub const ONIG_SYN_OP_ESC_X_BRACE_HEX8: u32 = 1073741824;
79pub const ONIG_SYN_OP_ESC_O_BRACE_OCTAL: u32 = 2147483648;
80pub const ONIG_SYN_OP2_ESC_CAPITAL_Q_QUOTE: u32 = 1;
81pub const ONIG_SYN_OP2_QMARK_GROUP_EFFECT: u32 = 2;
82pub const ONIG_SYN_OP2_OPTION_PERL: u32 = 4;
83pub const ONIG_SYN_OP2_OPTION_RUBY: u32 = 8;
84pub const ONIG_SYN_OP2_PLUS_POSSESSIVE_REPEAT: u32 = 16;
85pub const ONIG_SYN_OP2_PLUS_POSSESSIVE_INTERVAL: u32 = 32;
86pub const ONIG_SYN_OP2_CCLASS_SET_OP: u32 = 64;
87pub const ONIG_SYN_OP2_QMARK_LT_NAMED_GROUP: u32 = 128;
88pub const ONIG_SYN_OP2_ESC_K_NAMED_BACKREF: u32 = 256;
89pub const ONIG_SYN_OP2_ESC_G_SUBEXP_CALL: u32 = 512;
90pub const ONIG_SYN_OP2_ATMARK_CAPTURE_HISTORY: u32 = 1024;
91pub const ONIG_SYN_OP2_ESC_CAPITAL_C_BAR_CONTROL: u32 = 2048;
92pub const ONIG_SYN_OP2_ESC_CAPITAL_M_BAR_META: u32 = 4096;
93pub const ONIG_SYN_OP2_ESC_V_VTAB: u32 = 8192;
94pub const ONIG_SYN_OP2_ESC_U_HEX4: u32 = 16384;
95pub const ONIG_SYN_OP2_ESC_GNU_BUF_ANCHOR: u32 = 32768;
96pub const ONIG_SYN_OP2_ESC_P_BRACE_CHAR_PROPERTY: u32 = 65536;
97pub const ONIG_SYN_OP2_ESC_P_BRACE_CIRCUMFLEX_NOT: u32 = 131072;
98pub const ONIG_SYN_OP2_ESC_H_XDIGIT: u32 = 524288;
99pub const ONIG_SYN_OP2_INEFFECTIVE_ESCAPE: u32 = 1048576;
100pub const ONIG_SYN_OP2_QMARK_LPAREN_IF_ELSE: u32 = 2097152;
101pub const ONIG_SYN_OP2_ESC_CAPITAL_K_KEEP: u32 = 4194304;
102pub const ONIG_SYN_OP2_ESC_CAPITAL_R_GENERAL_NEWLINE: u32 = 8388608;
103pub const ONIG_SYN_OP2_ESC_CAPITAL_N_O_SUPER_DOT: u32 = 16777216;
104pub const ONIG_SYN_OP2_QMARK_TILDE_ABSENT_GROUP: u32 = 33554432;
105pub const ONIG_SYN_OP2_ESC_X_Y_GRAPHEME_CLUSTER: u32 = 67108864;
106pub const ONIG_SYN_OP2_ESC_X_Y_TEXT_SEGMENT: u32 = 67108864;
107pub const ONIG_SYN_OP2_QMARK_PERL_SUBEXP_CALL: u32 = 134217728;
108pub const ONIG_SYN_OP2_QMARK_BRACE_CALLOUT_CONTENTS: u32 = 268435456;
109pub const ONIG_SYN_OP2_ASTERISK_CALLOUT_NAME: u32 = 536870912;
110pub const ONIG_SYN_OP2_OPTION_ONIGURUMA: u32 = 1073741824;
111pub const ONIG_SYN_OP2_QMARK_CAPITAL_P_NAME: u32 = 2147483648;
112pub const ONIG_SYN_CONTEXT_INDEP_ANCHORS: u32 = 2147483648;
113pub const ONIG_SYN_CONTEXT_INDEP_REPEAT_OPS: u32 = 1;
114pub const ONIG_SYN_CONTEXT_INVALID_REPEAT_OPS: u32 = 2;
115pub const ONIG_SYN_ALLOW_UNMATCHED_CLOSE_SUBEXP: u32 = 4;
116pub const ONIG_SYN_ALLOW_INVALID_INTERVAL: u32 = 8;
117pub const ONIG_SYN_ALLOW_INTERVAL_LOW_ABBREV: u32 = 16;
118pub const ONIG_SYN_STRICT_CHECK_BACKREF: u32 = 32;
119pub const ONIG_SYN_DIFFERENT_LEN_ALT_LOOK_BEHIND: u32 = 64;
120pub const ONIG_SYN_CAPTURE_ONLY_NAMED_GROUP: u32 = 128;
121pub const ONIG_SYN_ALLOW_MULTIPLEX_DEFINITION_NAME: u32 = 256;
122pub const ONIG_SYN_FIXED_INTERVAL_IS_GREEDY_ONLY: u32 = 512;
123pub const ONIG_SYN_ISOLATED_OPTION_CONTINUE_BRANCH: u32 = 1024;
124pub const ONIG_SYN_VARIABLE_LEN_LOOK_BEHIND: u32 = 2048;
125pub const ONIG_SYN_PYTHON: u32 = 4096;
126pub const ONIG_SYN_WHOLE_OPTIONS: u32 = 8192;
127pub const ONIG_SYN_NOT_NEWLINE_IN_NEGATIVE_CC: u32 = 1048576;
128pub const ONIG_SYN_BACKSLASH_ESCAPE_IN_CC: u32 = 2097152;
129pub const ONIG_SYN_ALLOW_EMPTY_RANGE_IN_CC: u32 = 4194304;
130pub const ONIG_SYN_ALLOW_DOUBLE_RANGE_OP_IN_CC: u32 = 8388608;
131pub const ONIG_SYN_ALLOW_INVALID_CODE_END_OF_RANGE_IN_CC: u32 = 67108864;
132pub const ONIG_SYN_WARN_CC_OP_NOT_ESCAPED: u32 = 16777216;
133pub const ONIG_SYN_WARN_REDUNDANT_NESTED_REPEAT: u32 = 33554432;
134pub const ONIG_META_CHAR_ESCAPE: u32 = 0;
135pub const ONIG_META_CHAR_ANYCHAR: u32 = 1;
136pub const ONIG_META_CHAR_ANYTIME: u32 = 2;
137pub const ONIG_META_CHAR_ZERO_OR_ONE_TIME: u32 = 3;
138pub const ONIG_META_CHAR_ONE_OR_MORE_TIME: u32 = 4;
139pub const ONIG_META_CHAR_ANYCHAR_ANYTIME: u32 = 5;
140pub const ONIG_INEFFECTIVE_META_CHAR: u32 = 0;
141pub const ONIG_NORMAL: u32 = 0;
142pub const ONIG_VALUE_IS_NOT_SET: u32 = 1;
143pub const ONIG_MISMATCH: i32 = -1;
144pub const ONIG_NO_SUPPORT_CONFIG: i32 = -2;
145pub const ONIG_ABORT: i32 = -3;
146pub const ONIGERR_MEMORY: i32 = -5;
147pub const ONIGERR_TYPE_BUG: i32 = -6;
148pub const ONIGERR_PARSER_BUG: i32 = -11;
149pub const ONIGERR_STACK_BUG: i32 = -12;
150pub const ONIGERR_UNDEFINED_BYTECODE: i32 = -13;
151pub const ONIGERR_UNEXPECTED_BYTECODE: i32 = -14;
152pub const ONIGERR_MATCH_STACK_LIMIT_OVER: i32 = -15;
153pub const ONIGERR_PARSE_DEPTH_LIMIT_OVER: i32 = -16;
154pub const ONIGERR_RETRY_LIMIT_IN_MATCH_OVER: i32 = -17;
155pub const ONIGERR_RETRY_LIMIT_IN_SEARCH_OVER: i32 = -18;
156pub const ONIGERR_SUBEXP_CALL_LIMIT_IN_SEARCH_OVER: i32 = -19;
157pub const ONIGERR_DEFAULT_ENCODING_IS_NOT_SETTED: i32 = -21;
158pub const ONIGERR_DEFAULT_ENCODING_IS_NOT_SET: i32 = -21;
159pub const ONIGERR_SPECIFIED_ENCODING_CANT_CONVERT_TO_WIDE_CHAR: i32 = -22;
160pub const ONIGERR_FAIL_TO_INITIALIZE: i32 = -23;
161pub const ONIGERR_INVALID_ARGUMENT: i32 = -30;
162pub const ONIGERR_END_PATTERN_AT_LEFT_BRACE: i32 = -100;
163pub const ONIGERR_END_PATTERN_AT_LEFT_BRACKET: i32 = -101;
164pub const ONIGERR_EMPTY_CHAR_CLASS: i32 = -102;
165pub const ONIGERR_PREMATURE_END_OF_CHAR_CLASS: i32 = -103;
166pub const ONIGERR_END_PATTERN_AT_ESCAPE: i32 = -104;
167pub const ONIGERR_END_PATTERN_AT_META: i32 = -105;
168pub const ONIGERR_END_PATTERN_AT_CONTROL: i32 = -106;
169pub const ONIGERR_META_CODE_SYNTAX: i32 = -108;
170pub const ONIGERR_CONTROL_CODE_SYNTAX: i32 = -109;
171pub const ONIGERR_CHAR_CLASS_VALUE_AT_END_OF_RANGE: i32 = -110;
172pub const ONIGERR_CHAR_CLASS_VALUE_AT_START_OF_RANGE: i32 = -111;
173pub const ONIGERR_UNMATCHED_RANGE_SPECIFIER_IN_CHAR_CLASS: i32 = -112;
174pub const ONIGERR_TARGET_OF_REPEAT_OPERATOR_NOT_SPECIFIED: i32 = -113;
175pub const ONIGERR_TARGET_OF_REPEAT_OPERATOR_INVALID: i32 = -114;
176pub const ONIGERR_NESTED_REPEAT_OPERATOR: i32 = -115;
177pub const ONIGERR_UNMATCHED_CLOSE_PARENTHESIS: i32 = -116;
178pub const ONIGERR_END_PATTERN_WITH_UNMATCHED_PARENTHESIS: i32 = -117;
179pub const ONIGERR_END_PATTERN_IN_GROUP: i32 = -118;
180pub const ONIGERR_UNDEFINED_GROUP_OPTION: i32 = -119;
181pub const ONIGERR_INVALID_GROUP_OPTION: i32 = -120;
182pub const ONIGERR_INVALID_POSIX_BRACKET_TYPE: i32 = -121;
183pub const ONIGERR_INVALID_LOOK_BEHIND_PATTERN: i32 = -122;
184pub const ONIGERR_INVALID_REPEAT_RANGE_PATTERN: i32 = -123;
185pub const ONIGERR_TOO_BIG_NUMBER: i32 = -200;
186pub const ONIGERR_TOO_BIG_NUMBER_FOR_REPEAT_RANGE: i32 = -201;
187pub const ONIGERR_UPPER_SMALLER_THAN_LOWER_IN_REPEAT_RANGE: i32 = -202;
188pub const ONIGERR_EMPTY_RANGE_IN_CHAR_CLASS: i32 = -203;
189pub const ONIGERR_MISMATCH_CODE_LENGTH_IN_CLASS_RANGE: i32 = -204;
190pub const ONIGERR_TOO_MANY_MULTI_BYTE_RANGES: i32 = -205;
191pub const ONIGERR_TOO_SHORT_MULTI_BYTE_STRING: i32 = -206;
192pub const ONIGERR_TOO_BIG_BACKREF_NUMBER: i32 = -207;
193pub const ONIGERR_INVALID_BACKREF: i32 = -208;
194pub const ONIGERR_NUMBERED_BACKREF_OR_CALL_NOT_ALLOWED: i32 = -209;
195pub const ONIGERR_TOO_MANY_CAPTURES: i32 = -210;
196pub const ONIGERR_TOO_LONG_WIDE_CHAR_VALUE: i32 = -212;
197pub const ONIGERR_UNDEFINED_OPERATOR: i32 = -213;
198pub const ONIGERR_EMPTY_GROUP_NAME: i32 = -214;
199pub const ONIGERR_INVALID_GROUP_NAME: i32 = -215;
200pub const ONIGERR_INVALID_CHAR_IN_GROUP_NAME: i32 = -216;
201pub const ONIGERR_UNDEFINED_NAME_REFERENCE: i32 = -217;
202pub const ONIGERR_UNDEFINED_GROUP_REFERENCE: i32 = -218;
203pub const ONIGERR_MULTIPLEX_DEFINED_NAME: i32 = -219;
204pub const ONIGERR_MULTIPLEX_DEFINITION_NAME_CALL: i32 = -220;
205pub const ONIGERR_NEVER_ENDING_RECURSION: i32 = -221;
206pub const ONIGERR_GROUP_NUMBER_OVER_FOR_CAPTURE_HISTORY: i32 = -222;
207pub const ONIGERR_INVALID_CHAR_PROPERTY_NAME: i32 = -223;
208pub const ONIGERR_INVALID_IF_ELSE_SYNTAX: i32 = -224;
209pub const ONIGERR_INVALID_ABSENT_GROUP_PATTERN: i32 = -225;
210pub const ONIGERR_INVALID_ABSENT_GROUP_GENERATOR_PATTERN: i32 = -226;
211pub const ONIGERR_INVALID_CALLOUT_PATTERN: i32 = -227;
212pub const ONIGERR_INVALID_CALLOUT_NAME: i32 = -228;
213pub const ONIGERR_UNDEFINED_CALLOUT_NAME: i32 = -229;
214pub const ONIGERR_INVALID_CALLOUT_BODY: i32 = -230;
215pub const ONIGERR_INVALID_CALLOUT_TAG_NAME: i32 = -231;
216pub const ONIGERR_INVALID_CALLOUT_ARG: i32 = -232;
217pub const ONIGERR_INVALID_CODE_POINT_VALUE: i32 = -400;
218pub const ONIGERR_INVALID_WIDE_CHAR_VALUE: i32 = -400;
219pub const ONIGERR_TOO_BIG_WIDE_CHAR_VALUE: i32 = -401;
220pub const ONIGERR_NOT_SUPPORTED_ENCODING_COMBINATION: i32 = -402;
221pub const ONIGERR_INVALID_COMBINATION_OF_OPTIONS: i32 = -403;
222pub const ONIGERR_TOO_MANY_USER_DEFINED_OBJECTS: i32 = -404;
223pub const ONIGERR_TOO_LONG_PROPERTY_NAME: i32 = -405;
224pub const ONIGERR_VERY_INEFFICIENT_PATTERN: i32 = -406;
225pub const ONIGERR_LIBRARY_IS_NOT_INITIALIZED: i32 = -500;
226pub const ONIG_MAX_CAPTURE_HISTORY_GROUP: u32 = 31;
227pub const ONIG_TRAVERSE_CALLBACK_AT_FIRST: u32 = 1;
228pub const ONIG_TRAVERSE_CALLBACK_AT_LAST: u32 = 2;
229pub const ONIG_TRAVERSE_CALLBACK_AT_BOTH: u32 = 3;
230pub const ONIG_REGION_NOTPOS: i32 = -1;
231pub const ONIG_CHAR_TABLE_SIZE: u32 = 256;
232pub const ONIG_NON_NAME_ID: i32 = -1;
233pub const ONIG_NON_CALLOUT_NUM: u32 = 0;
234pub const ONIG_CALLOUT_MAX_ARGS_NUM: u32 = 4;
235pub const ONIG_CALLOUT_DATA_SLOT_NUM: u32 = 5;
236pub type OnigCodePoint = ::std::os::raw::c_uint;
237pub type OnigUChar = ::std::os::raw::c_uchar;
238pub type OnigCtype = ::std::os::raw::c_uint;
239pub type OnigLen = ::std::os::raw::c_uint;
240pub type OnigCaseFoldType = ::std::os::raw::c_uint;
241extern "C" {
242 pub static mut OnigDefaultCaseFoldFlag: OnigCaseFoldType;
243}
244#[repr(C)]
245#[derive(Debug, Copy, Clone, PartialEq, Eq)]
246pub struct OnigCaseFoldCodeItem {
247 pub byte_len: ::std::os::raw::c_int,
248 pub code_len: ::std::os::raw::c_int,
249 pub code: [OnigCodePoint; 3usize],
250}
251#[repr(C)]
252#[derive(Debug, Copy, Clone, PartialEq, Eq)]
253pub struct OnigMetaCharTableType {
254 pub esc: OnigCodePoint,
255 pub anychar: OnigCodePoint,
256 pub anytime: OnigCodePoint,
257 pub zero_or_one_time: OnigCodePoint,
258 pub one_or_more_time: OnigCodePoint,
259 pub anychar_anytime: OnigCodePoint,
260}
261pub type OnigApplyAllCaseFoldFunc = ::std::option::Option<
262 unsafe extern "C" fn(
263 from: OnigCodePoint,
264 to: *mut OnigCodePoint,
265 to_len: ::std::os::raw::c_int,
266 arg: *mut ::std::os::raw::c_void,
267 ) -> ::std::os::raw::c_int,
268>;
269#[repr(C)]
270#[derive(Debug, Copy, Clone, PartialEq, Eq)]
271pub struct OnigEncodingTypeST {
272 pub mbc_enc_len:
273 ::std::option::Option<unsafe extern "C" fn(p: *const OnigUChar) -> ::std::os::raw::c_int>,
274 pub name: *const ::std::os::raw::c_char,
275 pub max_enc_len: ::std::os::raw::c_int,
276 pub min_enc_len: ::std::os::raw::c_int,
277 pub is_mbc_newline: ::std::option::Option<
278 unsafe extern "C" fn(p: *const OnigUChar, end: *const OnigUChar) -> ::std::os::raw::c_int,
279 >,
280 pub mbc_to_code: ::std::option::Option<
281 unsafe extern "C" fn(p: *const OnigUChar, end: *const OnigUChar) -> OnigCodePoint,
282 >,
283 pub code_to_mbclen:
284 ::std::option::Option<unsafe extern "C" fn(code: OnigCodePoint) -> ::std::os::raw::c_int>,
285 pub code_to_mbc: ::std::option::Option<
286 unsafe extern "C" fn(code: OnigCodePoint, buf: *mut OnigUChar) -> ::std::os::raw::c_int,
287 >,
288 pub mbc_case_fold: ::std::option::Option<
289 unsafe extern "C" fn(
290 flag: OnigCaseFoldType,
291 pp: *mut *const OnigUChar,
292 end: *const OnigUChar,
293 to: *mut OnigUChar,
294 ) -> ::std::os::raw::c_int,
295 >,
296 pub apply_all_case_fold: ::std::option::Option<
297 unsafe extern "C" fn(
298 flag: OnigCaseFoldType,
299 f: OnigApplyAllCaseFoldFunc,
300 arg: *mut ::std::os::raw::c_void,
301 ) -> ::std::os::raw::c_int,
302 >,
303 pub get_case_fold_codes_by_str: ::std::option::Option<
304 unsafe extern "C" fn(
305 flag: OnigCaseFoldType,
306 p: *const OnigUChar,
307 end: *const OnigUChar,
308 acs: *mut OnigCaseFoldCodeItem,
309 ) -> ::std::os::raw::c_int,
310 >,
311 pub property_name_to_ctype: ::std::option::Option<
312 unsafe extern "C" fn(
313 enc: *mut OnigEncodingTypeST,
314 p: *mut OnigUChar,
315 end: *mut OnigUChar,
316 ) -> ::std::os::raw::c_int,
317 >,
318 pub is_code_ctype: ::std::option::Option<
319 unsafe extern "C" fn(code: OnigCodePoint, ctype: OnigCtype) -> ::std::os::raw::c_int,
320 >,
321 pub get_ctype_code_range: ::std::option::Option<
322 unsafe extern "C" fn(
323 ctype: OnigCtype,
324 sb_out: *mut OnigCodePoint,
325 ranges: *mut *const OnigCodePoint,
326 ) -> ::std::os::raw::c_int,
327 >,
328 pub left_adjust_char_head: ::std::option::Option<
329 unsafe extern "C" fn(start: *const OnigUChar, p: *const OnigUChar) -> *mut OnigUChar,
330 >,
331 pub is_allowed_reverse_match: ::std::option::Option<
332 unsafe extern "C" fn(p: *const OnigUChar, end: *const OnigUChar) -> ::std::os::raw::c_int,
333 >,
334 pub init: ::std::option::Option<unsafe extern "C" fn() -> ::std::os::raw::c_int>,
335 pub is_initialized: ::std::option::Option<unsafe extern "C" fn() -> ::std::os::raw::c_int>,
336 pub is_valid_mbc_string: ::std::option::Option<
337 unsafe extern "C" fn(s: *const OnigUChar, end: *const OnigUChar) -> ::std::os::raw::c_int,
338 >,
339 pub flag: ::std::os::raw::c_uint,
340 pub sb_range: OnigCodePoint,
341 pub index: ::std::os::raw::c_int,
342}
343pub type OnigEncodingType = OnigEncodingTypeST;
344pub type OnigEncoding = *mut OnigEncodingType;
345extern "C" {
346 pub static mut OnigEncodingASCII: OnigEncodingType;
347}
348extern "C" {
349 pub static mut OnigEncodingISO_8859_1: OnigEncodingType;
350}
351extern "C" {
352 pub static mut OnigEncodingISO_8859_2: OnigEncodingType;
353}
354extern "C" {
355 pub static mut OnigEncodingISO_8859_3: OnigEncodingType;
356}
357extern "C" {
358 pub static mut OnigEncodingISO_8859_4: OnigEncodingType;
359}
360extern "C" {
361 pub static mut OnigEncodingISO_8859_5: OnigEncodingType;
362}
363extern "C" {
364 pub static mut OnigEncodingISO_8859_6: OnigEncodingType;
365}
366extern "C" {
367 pub static mut OnigEncodingISO_8859_7: OnigEncodingType;
368}
369extern "C" {
370 pub static mut OnigEncodingISO_8859_8: OnigEncodingType;
371}
372extern "C" {
373 pub static mut OnigEncodingISO_8859_9: OnigEncodingType;
374}
375extern "C" {
376 pub static mut OnigEncodingISO_8859_10: OnigEncodingType;
377}
378extern "C" {
379 pub static mut OnigEncodingISO_8859_11: OnigEncodingType;
380}
381extern "C" {
382 pub static mut OnigEncodingISO_8859_13: OnigEncodingType;
383}
384extern "C" {
385 pub static mut OnigEncodingISO_8859_14: OnigEncodingType;
386}
387extern "C" {
388 pub static mut OnigEncodingISO_8859_15: OnigEncodingType;
389}
390extern "C" {
391 pub static mut OnigEncodingISO_8859_16: OnigEncodingType;
392}
393extern "C" {
394 pub static mut OnigEncodingUTF8: OnigEncodingType;
395}
396extern "C" {
397 pub static mut OnigEncodingUTF16_BE: OnigEncodingType;
398}
399extern "C" {
400 pub static mut OnigEncodingUTF16_LE: OnigEncodingType;
401}
402extern "C" {
403 pub static mut OnigEncodingUTF32_BE: OnigEncodingType;
404}
405extern "C" {
406 pub static mut OnigEncodingUTF32_LE: OnigEncodingType;
407}
408extern "C" {
409 pub static mut OnigEncodingEUC_JP: OnigEncodingType;
410}
411extern "C" {
412 pub static mut OnigEncodingEUC_TW: OnigEncodingType;
413}
414extern "C" {
415 pub static mut OnigEncodingEUC_KR: OnigEncodingType;
416}
417extern "C" {
418 pub static mut OnigEncodingEUC_CN: OnigEncodingType;
419}
420extern "C" {
421 pub static mut OnigEncodingSJIS: OnigEncodingType;
422}
423extern "C" {
424 pub static mut OnigEncodingKOI8: OnigEncodingType;
425}
426extern "C" {
427 pub static mut OnigEncodingKOI8_R: OnigEncodingType;
428}
429extern "C" {
430 pub static mut OnigEncodingCP1251: OnigEncodingType;
431}
432extern "C" {
433 pub static mut OnigEncodingBIG5: OnigEncodingType;
434}
435extern "C" {
436 pub static mut OnigEncodingGB18030: OnigEncodingType;
437}
438pub const OnigEncCtype_ONIGENC_CTYPE_NEWLINE: OnigEncCtype = 0;
439pub const OnigEncCtype_ONIGENC_CTYPE_ALPHA: OnigEncCtype = 1;
440pub const OnigEncCtype_ONIGENC_CTYPE_BLANK: OnigEncCtype = 2;
441pub const OnigEncCtype_ONIGENC_CTYPE_CNTRL: OnigEncCtype = 3;
442pub const OnigEncCtype_ONIGENC_CTYPE_DIGIT: OnigEncCtype = 4;
443pub const OnigEncCtype_ONIGENC_CTYPE_GRAPH: OnigEncCtype = 5;
444pub const OnigEncCtype_ONIGENC_CTYPE_LOWER: OnigEncCtype = 6;
445pub const OnigEncCtype_ONIGENC_CTYPE_PRINT: OnigEncCtype = 7;
446pub const OnigEncCtype_ONIGENC_CTYPE_PUNCT: OnigEncCtype = 8;
447pub const OnigEncCtype_ONIGENC_CTYPE_SPACE: OnigEncCtype = 9;
448pub const OnigEncCtype_ONIGENC_CTYPE_UPPER: OnigEncCtype = 10;
449pub const OnigEncCtype_ONIGENC_CTYPE_XDIGIT: OnigEncCtype = 11;
450pub const OnigEncCtype_ONIGENC_CTYPE_WORD: OnigEncCtype = 12;
451pub const OnigEncCtype_ONIGENC_CTYPE_ALNUM: OnigEncCtype = 13;
452pub const OnigEncCtype_ONIGENC_CTYPE_ASCII: OnigEncCtype = 14;
453pub type OnigEncCtype = ::std::os::raw::c_uint;
454extern "C" {
455 pub fn onigenc_step_back(
456 enc: OnigEncoding,
457 start: *const OnigUChar,
458 s: *const OnigUChar,
459 n: ::std::os::raw::c_int,
460 ) -> *mut OnigUChar;
461}
462extern "C" {
463 pub fn onigenc_init() -> ::std::os::raw::c_int;
464}
465extern "C" {
466 pub fn onig_initialize_encoding(enc: OnigEncoding) -> ::std::os::raw::c_int;
467}
468extern "C" {
469 pub fn onigenc_set_default_encoding(enc: OnigEncoding) -> ::std::os::raw::c_int;
470}
471extern "C" {
472 pub fn onigenc_get_default_encoding() -> OnigEncoding;
473}
474extern "C" {
475 pub fn onigenc_set_default_caseconv_table(table: *const OnigUChar);
476}
477extern "C" {
478 pub fn onigenc_get_right_adjust_char_head_with_prev(
479 enc: OnigEncoding,
480 start: *const OnigUChar,
481 s: *const OnigUChar,
482 prev: *mut *const OnigUChar,
483 ) -> *mut OnigUChar;
484}
485extern "C" {
486 pub fn onigenc_get_prev_char_head(
487 enc: OnigEncoding,
488 start: *const OnigUChar,
489 s: *const OnigUChar,
490 ) -> *mut OnigUChar;
491}
492extern "C" {
493 pub fn onigenc_get_left_adjust_char_head(
494 enc: OnigEncoding,
495 start: *const OnigUChar,
496 s: *const OnigUChar,
497 ) -> *mut OnigUChar;
498}
499extern "C" {
500 pub fn onigenc_get_right_adjust_char_head(
501 enc: OnigEncoding,
502 start: *const OnigUChar,
503 s: *const OnigUChar,
504 ) -> *mut OnigUChar;
505}
506extern "C" {
507 pub fn onigenc_strlen(
508 enc: OnigEncoding,
509 p: *const OnigUChar,
510 end: *const OnigUChar,
511 ) -> ::std::os::raw::c_int;
512}
513extern "C" {
514 pub fn onigenc_strlen_null(enc: OnigEncoding, p: *const OnigUChar) -> ::std::os::raw::c_int;
515}
516extern "C" {
517 pub fn onigenc_str_bytelen_null(
518 enc: OnigEncoding,
519 p: *const OnigUChar,
520 ) -> ::std::os::raw::c_int;
521}
522extern "C" {
523 pub fn onigenc_is_valid_mbc_string(
524 enc: OnigEncoding,
525 s: *const OnigUChar,
526 end: *const OnigUChar,
527 ) -> ::std::os::raw::c_int;
528}
529extern "C" {
530 pub fn onigenc_strdup(
531 enc: OnigEncoding,
532 s: *const OnigUChar,
533 end: *const OnigUChar,
534 ) -> *mut OnigUChar;
535}
536pub type OnigOptionType = ::std::os::raw::c_uint;
537#[repr(C)]
538#[derive(Debug, Copy, Clone, PartialEq, Eq)]
539pub struct OnigSyntaxType {
540 pub op: ::std::os::raw::c_uint,
541 pub op2: ::std::os::raw::c_uint,
542 pub behavior: ::std::os::raw::c_uint,
543 pub options: OnigOptionType,
544 pub meta_char_table: OnigMetaCharTableType,
545}
546extern "C" {
547 pub static mut OnigSyntaxASIS: OnigSyntaxType;
548}
549extern "C" {
550 pub static mut OnigSyntaxPosixBasic: OnigSyntaxType;
551}
552extern "C" {
553 pub static mut OnigSyntaxPosixExtended: OnigSyntaxType;
554}
555extern "C" {
556 pub static mut OnigSyntaxEmacs: OnigSyntaxType;
557}
558extern "C" {
559 pub static mut OnigSyntaxGrep: OnigSyntaxType;
560}
561extern "C" {
562 pub static mut OnigSyntaxGnuRegex: OnigSyntaxType;
563}
564extern "C" {
565 pub static mut OnigSyntaxJava: OnigSyntaxType;
566}
567extern "C" {
568 pub static mut OnigSyntaxPerl: OnigSyntaxType;
569}
570extern "C" {
571 pub static mut OnigSyntaxPerl_NG: OnigSyntaxType;
572}
573extern "C" {
574 pub static mut OnigSyntaxRuby: OnigSyntaxType;
575}
576extern "C" {
577 pub static mut OnigSyntaxPython: OnigSyntaxType;
578}
579extern "C" {
580 pub static mut OnigSyntaxOniguruma: OnigSyntaxType;
581}
582extern "C" {
583 pub static mut OnigDefaultSyntax: *mut OnigSyntaxType;
584}
585#[repr(C)]
586#[derive(Debug, Copy, Clone, PartialEq, Eq)]
587pub struct OnigCaptureTreeNodeStruct {
588 pub group: ::std::os::raw::c_int,
589 pub beg: ::std::os::raw::c_int,
590 pub end: ::std::os::raw::c_int,
591 pub allocated: ::std::os::raw::c_int,
592 pub num_childs: ::std::os::raw::c_int,
593 pub childs: *mut *mut OnigCaptureTreeNodeStruct,
594}
595pub type OnigCaptureTreeNode = OnigCaptureTreeNodeStruct;
596#[repr(C)]
597#[derive(Debug, Copy, Clone, PartialEq, Eq)]
598pub struct re_registers {
599 pub allocated: ::std::os::raw::c_int,
600 pub num_regs: ::std::os::raw::c_int,
601 pub beg: *mut ::std::os::raw::c_int,
602 pub end: *mut ::std::os::raw::c_int,
603 pub history_root: *mut OnigCaptureTreeNode,
604}
605pub type OnigRegion = re_registers;
606#[repr(C)]
607#[derive(Debug, Copy, Clone, PartialEq, Eq)]
608pub struct OnigErrorInfo {
609 pub enc: OnigEncoding,
610 pub par: *mut OnigUChar,
611 pub par_end: *mut OnigUChar,
612}
613#[repr(C)]
614#[derive(Debug, Copy, Clone, PartialEq, Eq)]
615pub struct OnigRepeatRange {
616 pub lower: ::std::os::raw::c_int,
617 pub upper: ::std::os::raw::c_int,
618}
619pub type OnigWarnFunc =
620 ::std::option::Option<unsafe extern "C" fn(s: *const ::std::os::raw::c_char)>;
621extern "C" {
622 pub fn onig_null_warn(s: *const ::std::os::raw::c_char);
623}
624#[repr(C)]
625#[derive(Debug, Copy, Clone)]
626pub struct re_pattern_buffer {
627 _unused: [u8; 0],
628}
629pub type OnigRegexType = re_pattern_buffer;
630pub type OnigRegex = *mut OnigRegexType;
631pub type regex_t = OnigRegexType;
632#[repr(C)]
633#[derive(Debug, Copy, Clone)]
634pub struct OnigRegSetStruct {
635 _unused: [u8; 0],
636}
637pub type OnigRegSet = OnigRegSetStruct;
638pub const OnigRegSetLead_ONIG_REGSET_POSITION_LEAD: OnigRegSetLead = 0;
639pub const OnigRegSetLead_ONIG_REGSET_REGEX_LEAD: OnigRegSetLead = 1;
640pub const OnigRegSetLead_ONIG_REGSET_PRIORITY_TO_REGEX_ORDER: OnigRegSetLead = 2;
641pub type OnigRegSetLead = ::std::os::raw::c_uint;
642#[repr(C)]
643#[derive(Debug, Copy, Clone, PartialEq, Eq)]
644pub struct OnigCompileInfo {
645 pub num_of_elements: ::std::os::raw::c_int,
646 pub pattern_enc: OnigEncoding,
647 pub target_enc: OnigEncoding,
648 pub syntax: *mut OnigSyntaxType,
649 pub option: OnigOptionType,
650 pub case_fold_flag: OnigCaseFoldType,
651}
652pub type OnigCallbackEachMatchFunc = ::std::option::Option<
653 unsafe extern "C" fn(
654 str_: *const OnigUChar,
655 end: *const OnigUChar,
656 match_start: *const OnigUChar,
657 region: *mut OnigRegion,
658 user_data: *mut ::std::os::raw::c_void,
659 ) -> ::std::os::raw::c_int,
660>;
661pub const OnigCalloutIn_ONIG_CALLOUT_IN_PROGRESS: OnigCalloutIn = 1;
662pub const OnigCalloutIn_ONIG_CALLOUT_IN_RETRACTION: OnigCalloutIn = 2;
663pub type OnigCalloutIn = ::std::os::raw::c_uint;
664pub const OnigCalloutOf_ONIG_CALLOUT_OF_CONTENTS: OnigCalloutOf = 0;
665pub const OnigCalloutOf_ONIG_CALLOUT_OF_NAME: OnigCalloutOf = 1;
666pub type OnigCalloutOf = ::std::os::raw::c_uint;
667pub const OnigCalloutType_ONIG_CALLOUT_TYPE_SINGLE: OnigCalloutType = 0;
668pub const OnigCalloutType_ONIG_CALLOUT_TYPE_START_CALL: OnigCalloutType = 1;
669pub const OnigCalloutType_ONIG_CALLOUT_TYPE_BOTH_CALL: OnigCalloutType = 2;
670pub const OnigCalloutType_ONIG_CALLOUT_TYPE_START_MARK_END_CALL: OnigCalloutType = 3;
671pub type OnigCalloutType = ::std::os::raw::c_uint;
672#[repr(C)]
673#[derive(Debug, Copy, Clone)]
674pub struct OnigCalloutArgsStruct {
675 _unused: [u8; 0],
676}
677pub type OnigCalloutArgs = OnigCalloutArgsStruct;
678pub type OnigCalloutFunc = ::std::option::Option<
679 unsafe extern "C" fn(
680 args: *mut OnigCalloutArgs,
681 user_data: *mut ::std::os::raw::c_void,
682 ) -> ::std::os::raw::c_int,
683>;
684pub const OnigCalloutResult_ONIG_CALLOUT_FAIL: OnigCalloutResult = 1;
685pub const OnigCalloutResult_ONIG_CALLOUT_SUCCESS: OnigCalloutResult = 0;
686pub type OnigCalloutResult = ::std::os::raw::c_uint;
687pub const OnigType_ONIG_TYPE_VOID: OnigType = 0;
688pub const OnigType_ONIG_TYPE_LONG: OnigType = 1;
689pub const OnigType_ONIG_TYPE_CHAR: OnigType = 2;
690pub const OnigType_ONIG_TYPE_STRING: OnigType = 4;
691pub const OnigType_ONIG_TYPE_POINTER: OnigType = 8;
692pub const OnigType_ONIG_TYPE_TAG: OnigType = 16;
693pub type OnigType = ::std::os::raw::c_uint;
694#[repr(C)]
695#[derive(Copy, Clone)]
696pub union OnigValue {
697 pub l: ::std::os::raw::c_long,
698 pub c: OnigCodePoint,
699 pub s: OnigValue__bindgen_ty_1,
700 pub p: *mut ::std::os::raw::c_void,
701 pub tag: ::std::os::raw::c_int,
702}
703#[repr(C)]
704#[derive(Debug, Copy, Clone, PartialEq, Eq)]
705pub struct OnigValue__bindgen_ty_1 {
706 pub start: *mut OnigUChar,
707 pub end: *mut OnigUChar,
708}
709#[repr(C)]
710#[derive(Debug, Copy, Clone)]
711pub struct OnigMatchParamStruct {
712 _unused: [u8; 0],
713}
714pub type OnigMatchParam = OnigMatchParamStruct;
715extern "C" {
716 pub fn onig_initialize(
717 encodings: *mut OnigEncoding,
718 number_of_encodings: ::std::os::raw::c_int,
719 ) -> ::std::os::raw::c_int;
720}
721extern "C" {
722 pub fn onig_init() -> ::std::os::raw::c_int;
723}
724extern "C" {
725 pub fn onig_error_code_to_str(
726 s: *mut OnigUChar,
727 err_code: ::std::os::raw::c_int,
728 ...
729 ) -> ::std::os::raw::c_int;
730}
731extern "C" {
732 pub fn onig_is_error_code_needs_param(code: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
733}
734extern "C" {
735 pub fn onig_set_warn_func(f: OnigWarnFunc);
736}
737extern "C" {
738 pub fn onig_set_verb_warn_func(f: OnigWarnFunc);
739}
740extern "C" {
741 pub fn onig_new(
742 arg1: *mut OnigRegex,
743 pattern: *const OnigUChar,
744 pattern_end: *const OnigUChar,
745 option: OnigOptionType,
746 enc: OnigEncoding,
747 syntax: *mut OnigSyntaxType,
748 einfo: *mut OnigErrorInfo,
749 ) -> ::std::os::raw::c_int;
750}
751extern "C" {
752 pub fn onig_reg_init(
753 reg: OnigRegex,
754 option: OnigOptionType,
755 case_fold_flag: OnigCaseFoldType,
756 enc: OnigEncoding,
757 syntax: *mut OnigSyntaxType,
758 ) -> ::std::os::raw::c_int;
759}
760extern "C" {
761 pub fn onig_new_without_alloc(
762 arg1: OnigRegex,
763 pattern: *const OnigUChar,
764 pattern_end: *const OnigUChar,
765 option: OnigOptionType,
766 enc: OnigEncoding,
767 syntax: *mut OnigSyntaxType,
768 einfo: *mut OnigErrorInfo,
769 ) -> ::std::os::raw::c_int;
770}
771extern "C" {
772 pub fn onig_new_deluxe(
773 reg: *mut OnigRegex,
774 pattern: *const OnigUChar,
775 pattern_end: *const OnigUChar,
776 ci: *mut OnigCompileInfo,
777 einfo: *mut OnigErrorInfo,
778 ) -> ::std::os::raw::c_int;
779}
780extern "C" {
781 pub fn onig_free(arg1: OnigRegex);
782}
783extern "C" {
784 pub fn onig_free_body(arg1: OnigRegex);
785}
786extern "C" {
787 pub fn onig_scan(
788 reg: OnigRegex,
789 str_: *const OnigUChar,
790 end: *const OnigUChar,
791 region: *mut OnigRegion,
792 option: OnigOptionType,
793 scan_callback: ::std::option::Option<
794 unsafe extern "C" fn(
795 arg1: ::std::os::raw::c_int,
796 arg2: ::std::os::raw::c_int,
797 arg3: *mut OnigRegion,
798 arg4: *mut ::std::os::raw::c_void,
799 ) -> ::std::os::raw::c_int,
800 >,
801 callback_arg: *mut ::std::os::raw::c_void,
802 ) -> ::std::os::raw::c_int;
803}
804extern "C" {
805 pub fn onig_search(
806 arg1: OnigRegex,
807 str_: *const OnigUChar,
808 end: *const OnigUChar,
809 start: *const OnigUChar,
810 range: *const OnigUChar,
811 region: *mut OnigRegion,
812 option: OnigOptionType,
813 ) -> ::std::os::raw::c_int;
814}
815extern "C" {
816 pub fn onig_search_with_param(
817 arg1: OnigRegex,
818 str_: *const OnigUChar,
819 end: *const OnigUChar,
820 start: *const OnigUChar,
821 range: *const OnigUChar,
822 region: *mut OnigRegion,
823 option: OnigOptionType,
824 mp: *mut OnigMatchParam,
825 ) -> ::std::os::raw::c_int;
826}
827extern "C" {
828 pub fn onig_match(
829 arg1: OnigRegex,
830 str_: *const OnigUChar,
831 end: *const OnigUChar,
832 at: *const OnigUChar,
833 region: *mut OnigRegion,
834 option: OnigOptionType,
835 ) -> ::std::os::raw::c_int;
836}
837extern "C" {
838 pub fn onig_match_with_param(
839 arg1: OnigRegex,
840 str_: *const OnigUChar,
841 end: *const OnigUChar,
842 at: *const OnigUChar,
843 region: *mut OnigRegion,
844 option: OnigOptionType,
845 mp: *mut OnigMatchParam,
846 ) -> ::std::os::raw::c_int;
847}
848extern "C" {
849 pub fn onig_regset_new(
850 rset: *mut *mut OnigRegSet,
851 n: ::std::os::raw::c_int,
852 regs: *mut OnigRegex,
853 ) -> ::std::os::raw::c_int;
854}
855extern "C" {
856 pub fn onig_regset_add(set: *mut OnigRegSet, reg: OnigRegex) -> ::std::os::raw::c_int;
857}
858extern "C" {
859 pub fn onig_regset_replace(
860 set: *mut OnigRegSet,
861 at: ::std::os::raw::c_int,
862 reg: OnigRegex,
863 ) -> ::std::os::raw::c_int;
864}
865extern "C" {
866 pub fn onig_regset_free(set: *mut OnigRegSet);
867}
868extern "C" {
869 pub fn onig_regset_number_of_regex(set: *mut OnigRegSet) -> ::std::os::raw::c_int;
870}
871extern "C" {
872 pub fn onig_regset_get_regex(set: *mut OnigRegSet, at: ::std::os::raw::c_int) -> OnigRegex;
873}
874extern "C" {
875 pub fn onig_regset_get_region(
876 set: *mut OnigRegSet,
877 at: ::std::os::raw::c_int,
878 ) -> *mut OnigRegion;
879}
880extern "C" {
881 pub fn onig_regset_search(
882 set: *mut OnigRegSet,
883 str_: *const OnigUChar,
884 end: *const OnigUChar,
885 start: *const OnigUChar,
886 range: *const OnigUChar,
887 lead: OnigRegSetLead,
888 option: OnigOptionType,
889 rmatch_pos: *mut ::std::os::raw::c_int,
890 ) -> ::std::os::raw::c_int;
891}
892extern "C" {
893 pub fn onig_regset_search_with_param(
894 set: *mut OnigRegSet,
895 str_: *const OnigUChar,
896 end: *const OnigUChar,
897 start: *const OnigUChar,
898 range: *const OnigUChar,
899 lead: OnigRegSetLead,
900 option: OnigOptionType,
901 mps: *mut *mut OnigMatchParam,
902 rmatch_pos: *mut ::std::os::raw::c_int,
903 ) -> ::std::os::raw::c_int;
904}
905extern "C" {
906 pub fn onig_region_new() -> *mut OnigRegion;
907}
908extern "C" {
909 pub fn onig_region_init(region: *mut OnigRegion);
910}
911extern "C" {
912 pub fn onig_region_free(region: *mut OnigRegion, free_self: ::std::os::raw::c_int);
913}
914extern "C" {
915 pub fn onig_region_copy(to: *mut OnigRegion, from: *mut OnigRegion);
916}
917extern "C" {
918 pub fn onig_region_clear(region: *mut OnigRegion);
919}
920extern "C" {
921 pub fn onig_region_resize(
922 region: *mut OnigRegion,
923 n: ::std::os::raw::c_int,
924 ) -> ::std::os::raw::c_int;
925}
926extern "C" {
927 pub fn onig_region_set(
928 region: *mut OnigRegion,
929 at: ::std::os::raw::c_int,
930 beg: ::std::os::raw::c_int,
931 end: ::std::os::raw::c_int,
932 ) -> ::std::os::raw::c_int;
933}
934extern "C" {
935 pub fn onig_name_to_group_numbers(
936 reg: OnigRegex,
937 name: *const OnigUChar,
938 name_end: *const OnigUChar,
939 nums: *mut *mut ::std::os::raw::c_int,
940 ) -> ::std::os::raw::c_int;
941}
942extern "C" {
943 pub fn onig_name_to_backref_number(
944 reg: OnigRegex,
945 name: *const OnigUChar,
946 name_end: *const OnigUChar,
947 region: *mut OnigRegion,
948 ) -> ::std::os::raw::c_int;
949}
950extern "C" {
951 pub fn onig_foreach_name(
952 reg: OnigRegex,
953 func: ::std::option::Option<
954 unsafe extern "C" fn(
955 arg1: *const OnigUChar,
956 arg2: *const OnigUChar,
957 arg3: ::std::os::raw::c_int,
958 arg4: *mut ::std::os::raw::c_int,
959 arg5: OnigRegex,
960 arg6: *mut ::std::os::raw::c_void,
961 ) -> ::std::os::raw::c_int,
962 >,
963 arg: *mut ::std::os::raw::c_void,
964 ) -> ::std::os::raw::c_int;
965}
966extern "C" {
967 pub fn onig_number_of_names(reg: OnigRegex) -> ::std::os::raw::c_int;
968}
969extern "C" {
970 pub fn onig_number_of_captures(reg: OnigRegex) -> ::std::os::raw::c_int;
971}
972extern "C" {
973 pub fn onig_number_of_capture_histories(reg: OnigRegex) -> ::std::os::raw::c_int;
974}
975extern "C" {
976 pub fn onig_get_capture_tree(region: *mut OnigRegion) -> *mut OnigCaptureTreeNode;
977}
978extern "C" {
979 pub fn onig_capture_tree_traverse(
980 region: *mut OnigRegion,
981 at: ::std::os::raw::c_int,
982 callback_func: ::std::option::Option<
983 unsafe extern "C" fn(
984 arg1: ::std::os::raw::c_int,
985 arg2: ::std::os::raw::c_int,
986 arg3: ::std::os::raw::c_int,
987 arg4: ::std::os::raw::c_int,
988 arg5: ::std::os::raw::c_int,
989 arg6: *mut ::std::os::raw::c_void,
990 ) -> ::std::os::raw::c_int,
991 >,
992 arg: *mut ::std::os::raw::c_void,
993 ) -> ::std::os::raw::c_int;
994}
995extern "C" {
996 pub fn onig_noname_group_capture_is_active(reg: OnigRegex) -> ::std::os::raw::c_int;
997}
998extern "C" {
999 pub fn onig_get_encoding(reg: OnigRegex) -> OnigEncoding;
1000}
1001extern "C" {
1002 pub fn onig_get_options(reg: OnigRegex) -> OnigOptionType;
1003}
1004extern "C" {
1005 pub fn onig_get_case_fold_flag(reg: OnigRegex) -> OnigCaseFoldType;
1006}
1007extern "C" {
1008 pub fn onig_get_syntax(reg: OnigRegex) -> *mut OnigSyntaxType;
1009}
1010extern "C" {
1011 pub fn onig_set_default_syntax(syntax: *mut OnigSyntaxType) -> ::std::os::raw::c_int;
1012}
1013extern "C" {
1014 pub fn onig_copy_syntax(to: *mut OnigSyntaxType, from: *mut OnigSyntaxType);
1015}
1016extern "C" {
1017 pub fn onig_get_syntax_op(syntax: *mut OnigSyntaxType) -> ::std::os::raw::c_uint;
1018}
1019extern "C" {
1020 pub fn onig_get_syntax_op2(syntax: *mut OnigSyntaxType) -> ::std::os::raw::c_uint;
1021}
1022extern "C" {
1023 pub fn onig_get_syntax_behavior(syntax: *mut OnigSyntaxType) -> ::std::os::raw::c_uint;
1024}
1025extern "C" {
1026 pub fn onig_get_syntax_options(syntax: *mut OnigSyntaxType) -> OnigOptionType;
1027}
1028extern "C" {
1029 pub fn onig_set_syntax_op(syntax: *mut OnigSyntaxType, op: ::std::os::raw::c_uint);
1030}
1031extern "C" {
1032 pub fn onig_set_syntax_op2(syntax: *mut OnigSyntaxType, op2: ::std::os::raw::c_uint);
1033}
1034extern "C" {
1035 pub fn onig_set_syntax_behavior(syntax: *mut OnigSyntaxType, behavior: ::std::os::raw::c_uint);
1036}
1037extern "C" {
1038 pub fn onig_set_syntax_options(syntax: *mut OnigSyntaxType, options: OnigOptionType);
1039}
1040extern "C" {
1041 pub fn onig_set_meta_char(
1042 syntax: *mut OnigSyntaxType,
1043 what: ::std::os::raw::c_uint,
1044 code: OnigCodePoint,
1045 ) -> ::std::os::raw::c_int;
1046}
1047extern "C" {
1048 pub fn onig_copy_encoding(to: OnigEncoding, from: OnigEncoding);
1049}
1050extern "C" {
1051 pub fn onig_get_default_case_fold_flag() -> OnigCaseFoldType;
1052}
1053extern "C" {
1054 pub fn onig_set_default_case_fold_flag(
1055 case_fold_flag: OnigCaseFoldType,
1056 ) -> ::std::os::raw::c_int;
1057}
1058extern "C" {
1059 pub fn onig_get_match_stack_limit_size() -> ::std::os::raw::c_uint;
1060}
1061extern "C" {
1062 pub fn onig_set_match_stack_limit_size(size: ::std::os::raw::c_uint) -> ::std::os::raw::c_int;
1063}
1064extern "C" {
1065 pub fn onig_get_retry_limit_in_match() -> ::std::os::raw::c_ulong;
1066}
1067extern "C" {
1068 pub fn onig_set_retry_limit_in_match(n: ::std::os::raw::c_ulong) -> ::std::os::raw::c_int;
1069}
1070extern "C" {
1071 pub fn onig_get_retry_limit_in_search() -> ::std::os::raw::c_ulong;
1072}
1073extern "C" {
1074 pub fn onig_set_retry_limit_in_search(n: ::std::os::raw::c_ulong) -> ::std::os::raw::c_int;
1075}
1076extern "C" {
1077 pub fn onig_get_parse_depth_limit() -> ::std::os::raw::c_uint;
1078}
1079extern "C" {
1080 pub fn onig_set_capture_num_limit(num: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
1081}
1082extern "C" {
1083 pub fn onig_set_parse_depth_limit(depth: ::std::os::raw::c_uint) -> ::std::os::raw::c_int;
1084}
1085extern "C" {
1086 pub fn onig_get_subexp_call_limit_in_search() -> ::std::os::raw::c_ulong;
1087}
1088extern "C" {
1089 pub fn onig_set_subexp_call_limit_in_search(
1090 n: ::std::os::raw::c_ulong,
1091 ) -> ::std::os::raw::c_int;
1092}
1093extern "C" {
1094 pub fn onig_get_subexp_call_max_nest_level() -> ::std::os::raw::c_int;
1095}
1096extern "C" {
1097 pub fn onig_set_subexp_call_max_nest_level(
1098 level: ::std::os::raw::c_int,
1099 ) -> ::std::os::raw::c_int;
1100}
1101extern "C" {
1102 pub fn onig_unicode_define_user_property(
1103 name: *const ::std::os::raw::c_char,
1104 ranges: *mut OnigCodePoint,
1105 ) -> ::std::os::raw::c_int;
1106}
1107extern "C" {
1108 pub fn onig_end() -> ::std::os::raw::c_int;
1109}
1110extern "C" {
1111 pub fn onig_version() -> *const ::std::os::raw::c_char;
1112}
1113extern "C" {
1114 pub fn onig_copyright() -> *const ::std::os::raw::c_char;
1115}
1116extern "C" {
1117 pub fn onig_get_callback_each_match() -> OnigCallbackEachMatchFunc;
1118}
1119extern "C" {
1120 pub fn onig_set_callback_each_match(f: OnigCallbackEachMatchFunc) -> ::std::os::raw::c_int;
1121}
1122extern "C" {
1123 pub fn onig_new_match_param() -> *mut OnigMatchParam;
1124}
1125extern "C" {
1126 pub fn onig_free_match_param(p: *mut OnigMatchParam);
1127}
1128extern "C" {
1129 pub fn onig_free_match_param_content(p: *mut OnigMatchParam);
1130}
1131extern "C" {
1132 pub fn onig_initialize_match_param(mp: *mut OnigMatchParam) -> ::std::os::raw::c_int;
1133}
1134extern "C" {
1135 pub fn onig_set_match_stack_limit_size_of_match_param(
1136 param: *mut OnigMatchParam,
1137 limit: ::std::os::raw::c_uint,
1138 ) -> ::std::os::raw::c_int;
1139}
1140extern "C" {
1141 pub fn onig_set_retry_limit_in_match_of_match_param(
1142 param: *mut OnigMatchParam,
1143 limit: ::std::os::raw::c_ulong,
1144 ) -> ::std::os::raw::c_int;
1145}
1146extern "C" {
1147 pub fn onig_set_retry_limit_in_search_of_match_param(
1148 param: *mut OnigMatchParam,
1149 limit: ::std::os::raw::c_ulong,
1150 ) -> ::std::os::raw::c_int;
1151}
1152extern "C" {
1153 pub fn onig_set_progress_callout_of_match_param(
1154 param: *mut OnigMatchParam,
1155 f: OnigCalloutFunc,
1156 ) -> ::std::os::raw::c_int;
1157}
1158extern "C" {
1159 pub fn onig_set_retraction_callout_of_match_param(
1160 param: *mut OnigMatchParam,
1161 f: OnigCalloutFunc,
1162 ) -> ::std::os::raw::c_int;
1163}
1164extern "C" {
1165 pub fn onig_set_callout_user_data_of_match_param(
1166 param: *mut OnigMatchParam,
1167 user_data: *mut ::std::os::raw::c_void,
1168 ) -> ::std::os::raw::c_int;
1169}
1170extern "C" {
1171 pub fn onig_get_progress_callout() -> OnigCalloutFunc;
1172}
1173extern "C" {
1174 pub fn onig_set_progress_callout(f: OnigCalloutFunc) -> ::std::os::raw::c_int;
1175}
1176extern "C" {
1177 pub fn onig_get_retraction_callout() -> OnigCalloutFunc;
1178}
1179extern "C" {
1180 pub fn onig_set_retraction_callout(f: OnigCalloutFunc) -> ::std::os::raw::c_int;
1181}
1182extern "C" {
1183 pub fn onig_set_callout_of_name(
1184 enc: OnigEncoding,
1185 type_: OnigCalloutType,
1186 name: *mut OnigUChar,
1187 name_end: *mut OnigUChar,
1188 callout_in: ::std::os::raw::c_int,
1189 callout: OnigCalloutFunc,
1190 end_callout: OnigCalloutFunc,
1191 arg_num: ::std::os::raw::c_int,
1192 arg_types: *mut ::std::os::raw::c_uint,
1193 optional_arg_num: ::std::os::raw::c_int,
1194 opt_defaults: *mut OnigValue,
1195 ) -> ::std::os::raw::c_int;
1196}
1197extern "C" {
1198 pub fn onig_get_callout_name_by_name_id(id: ::std::os::raw::c_int) -> *mut OnigUChar;
1199}
1200extern "C" {
1201 pub fn onig_get_callout_num_by_tag(
1202 reg: OnigRegex,
1203 tag: *const OnigUChar,
1204 tag_end: *const OnigUChar,
1205 ) -> ::std::os::raw::c_int;
1206}
1207extern "C" {
1208 pub fn onig_get_callout_data_by_tag(
1209 reg: OnigRegex,
1210 mp: *mut OnigMatchParam,
1211 tag: *const OnigUChar,
1212 tag_end: *const OnigUChar,
1213 slot: ::std::os::raw::c_int,
1214 type_: *mut OnigType,
1215 val: *mut OnigValue,
1216 ) -> ::std::os::raw::c_int;
1217}
1218extern "C" {
1219 pub fn onig_set_callout_data_by_tag(
1220 reg: OnigRegex,
1221 mp: *mut OnigMatchParam,
1222 tag: *const OnigUChar,
1223 tag_end: *const OnigUChar,
1224 slot: ::std::os::raw::c_int,
1225 type_: OnigType,
1226 val: *mut OnigValue,
1227 ) -> ::std::os::raw::c_int;
1228}
1229extern "C" {
1230 pub fn onig_get_callout_data_by_tag_dont_clear_old(
1231 reg: OnigRegex,
1232 mp: *mut OnigMatchParam,
1233 tag: *const OnigUChar,
1234 tag_end: *const OnigUChar,
1235 slot: ::std::os::raw::c_int,
1236 type_: *mut OnigType,
1237 val: *mut OnigValue,
1238 ) -> ::std::os::raw::c_int;
1239}
1240extern "C" {
1241 pub fn onig_get_callout_num_by_callout_args(
1242 args: *mut OnigCalloutArgs,
1243 ) -> ::std::os::raw::c_int;
1244}
1245extern "C" {
1246 pub fn onig_get_callout_in_by_callout_args(args: *mut OnigCalloutArgs) -> OnigCalloutIn;
1247}
1248extern "C" {
1249 pub fn onig_get_name_id_by_callout_args(args: *mut OnigCalloutArgs) -> ::std::os::raw::c_int;
1250}
1251extern "C" {
1252 pub fn onig_get_contents_by_callout_args(args: *mut OnigCalloutArgs) -> *const OnigUChar;
1253}
1254extern "C" {
1255 pub fn onig_get_contents_end_by_callout_args(args: *mut OnigCalloutArgs) -> *const OnigUChar;
1256}
1257extern "C" {
1258 pub fn onig_get_args_num_by_callout_args(args: *mut OnigCalloutArgs) -> ::std::os::raw::c_int;
1259}
1260extern "C" {
1261 pub fn onig_get_passed_args_num_by_callout_args(
1262 args: *mut OnigCalloutArgs,
1263 ) -> ::std::os::raw::c_int;
1264}
1265extern "C" {
1266 pub fn onig_get_arg_by_callout_args(
1267 args: *mut OnigCalloutArgs,
1268 index: ::std::os::raw::c_int,
1269 type_: *mut OnigType,
1270 val: *mut OnigValue,
1271 ) -> ::std::os::raw::c_int;
1272}
1273extern "C" {
1274 pub fn onig_get_string_by_callout_args(args: *mut OnigCalloutArgs) -> *const OnigUChar;
1275}
1276extern "C" {
1277 pub fn onig_get_string_end_by_callout_args(args: *mut OnigCalloutArgs) -> *const OnigUChar;
1278}
1279extern "C" {
1280 pub fn onig_get_start_by_callout_args(args: *mut OnigCalloutArgs) -> *const OnigUChar;
1281}
1282extern "C" {
1283 pub fn onig_get_right_range_by_callout_args(args: *mut OnigCalloutArgs) -> *const OnigUChar;
1284}
1285extern "C" {
1286 pub fn onig_get_current_by_callout_args(args: *mut OnigCalloutArgs) -> *const OnigUChar;
1287}
1288extern "C" {
1289 pub fn onig_get_regex_by_callout_args(args: *mut OnigCalloutArgs) -> OnigRegex;
1290}
1291extern "C" {
1292 pub fn onig_get_retry_counter_by_callout_args(
1293 args: *mut OnigCalloutArgs,
1294 ) -> ::std::os::raw::c_ulong;
1295}
1296extern "C" {
1297 pub fn onig_callout_tag_is_exist_at_callout_num(
1298 reg: OnigRegex,
1299 callout_num: ::std::os::raw::c_int,
1300 ) -> ::std::os::raw::c_int;
1301}
1302extern "C" {
1303 pub fn onig_get_callout_tag_start(
1304 reg: OnigRegex,
1305 callout_num: ::std::os::raw::c_int,
1306 ) -> *const OnigUChar;
1307}
1308extern "C" {
1309 pub fn onig_get_callout_tag_end(
1310 reg: OnigRegex,
1311 callout_num: ::std::os::raw::c_int,
1312 ) -> *const OnigUChar;
1313}
1314extern "C" {
1315 pub fn onig_get_callout_data_dont_clear_old(
1316 reg: OnigRegex,
1317 mp: *mut OnigMatchParam,
1318 callout_num: ::std::os::raw::c_int,
1319 slot: ::std::os::raw::c_int,
1320 type_: *mut OnigType,
1321 val: *mut OnigValue,
1322 ) -> ::std::os::raw::c_int;
1323}
1324extern "C" {
1325 pub fn onig_get_callout_data_by_callout_args_self_dont_clear_old(
1326 args: *mut OnigCalloutArgs,
1327 slot: ::std::os::raw::c_int,
1328 type_: *mut OnigType,
1329 val: *mut OnigValue,
1330 ) -> ::std::os::raw::c_int;
1331}
1332extern "C" {
1333 pub fn onig_get_callout_data(
1334 reg: OnigRegex,
1335 mp: *mut OnigMatchParam,
1336 callout_num: ::std::os::raw::c_int,
1337 slot: ::std::os::raw::c_int,
1338 type_: *mut OnigType,
1339 val: *mut OnigValue,
1340 ) -> ::std::os::raw::c_int;
1341}
1342extern "C" {
1343 pub fn onig_get_callout_data_by_callout_args(
1344 args: *mut OnigCalloutArgs,
1345 callout_num: ::std::os::raw::c_int,
1346 slot: ::std::os::raw::c_int,
1347 type_: *mut OnigType,
1348 val: *mut OnigValue,
1349 ) -> ::std::os::raw::c_int;
1350}
1351extern "C" {
1352 pub fn onig_get_callout_data_by_callout_args_self(
1353 args: *mut OnigCalloutArgs,
1354 slot: ::std::os::raw::c_int,
1355 type_: *mut OnigType,
1356 val: *mut OnigValue,
1357 ) -> ::std::os::raw::c_int;
1358}
1359extern "C" {
1360 pub fn onig_set_callout_data(
1361 reg: OnigRegex,
1362 mp: *mut OnigMatchParam,
1363 callout_num: ::std::os::raw::c_int,
1364 slot: ::std::os::raw::c_int,
1365 type_: OnigType,
1366 val: *mut OnigValue,
1367 ) -> ::std::os::raw::c_int;
1368}
1369extern "C" {
1370 pub fn onig_set_callout_data_by_callout_args(
1371 args: *mut OnigCalloutArgs,
1372 callout_num: ::std::os::raw::c_int,
1373 slot: ::std::os::raw::c_int,
1374 type_: OnigType,
1375 val: *mut OnigValue,
1376 ) -> ::std::os::raw::c_int;
1377}
1378extern "C" {
1379 pub fn onig_set_callout_data_by_callout_args_self(
1380 args: *mut OnigCalloutArgs,
1381 slot: ::std::os::raw::c_int,
1382 type_: OnigType,
1383 val: *mut OnigValue,
1384 ) -> ::std::os::raw::c_int;
1385}
1386extern "C" {
1387 pub fn onig_get_capture_range_in_callout(
1388 args: *mut OnigCalloutArgs,
1389 mem_num: ::std::os::raw::c_int,
1390 begin: *mut ::std::os::raw::c_int,
1391 end: *mut ::std::os::raw::c_int,
1392 ) -> ::std::os::raw::c_int;
1393}
1394extern "C" {
1395 pub fn onig_get_used_stack_size_in_callout(
1396 args: *mut OnigCalloutArgs,
1397 used_num: *mut ::std::os::raw::c_int,
1398 used_bytes: *mut ::std::os::raw::c_int,
1399 ) -> ::std::os::raw::c_int;
1400}
1401extern "C" {
1402 pub fn onig_builtin_fail(
1403 args: *mut OnigCalloutArgs,
1404 user_data: *mut ::std::os::raw::c_void,
1405 ) -> ::std::os::raw::c_int;
1406}
1407extern "C" {
1408 pub fn onig_builtin_mismatch(
1409 args: *mut OnigCalloutArgs,
1410 user_data: *mut ::std::os::raw::c_void,
1411 ) -> ::std::os::raw::c_int;
1412}
1413extern "C" {
1414 pub fn onig_builtin_error(
1415 args: *mut OnigCalloutArgs,
1416 user_data: *mut ::std::os::raw::c_void,
1417 ) -> ::std::os::raw::c_int;
1418}
1419extern "C" {
1420 pub fn onig_builtin_count(
1421 args: *mut OnigCalloutArgs,
1422 user_data: *mut ::std::os::raw::c_void,
1423 ) -> ::std::os::raw::c_int;
1424}
1425extern "C" {
1426 pub fn onig_builtin_total_count(
1427 args: *mut OnigCalloutArgs,
1428 user_data: *mut ::std::os::raw::c_void,
1429 ) -> ::std::os::raw::c_int;
1430}
1431extern "C" {
1432 pub fn onig_builtin_max(
1433 args: *mut OnigCalloutArgs,
1434 user_data: *mut ::std::os::raw::c_void,
1435 ) -> ::std::os::raw::c_int;
1436}
1437extern "C" {
1438 pub fn onig_builtin_cmp(
1439 args: *mut OnigCalloutArgs,
1440 user_data: *mut ::std::os::raw::c_void,
1441 ) -> ::std::os::raw::c_int;
1442}
1443extern "C" {
1444 pub fn onig_setup_builtin_monitors_by_ascii_encoded_name(
1445 fp: *mut ::std::os::raw::c_void,
1446 ) -> ::std::os::raw::c_int;
1447}