| 6 |
and semantics are as close as possible to those of the Perl 5 language. |
and semantics are as close as possible to those of the Perl 5 language. |
| 7 |
|
|
| 8 |
Written by Philip Hazel |
Written by Philip Hazel |
| 9 |
Copyright (c) 1997-2010 University of Cambridge |
Copyright (c) 1997-2012 University of Cambridge |
| 10 |
|
|
| 11 |
----------------------------------------------------------------------------- |
----------------------------------------------------------------------------- |
| 12 |
Redistribution and use in source and binary forms, with or without |
Redistribution and use in source and binary forms, with or without |
| 154 |
REG_BADPAT, /* \c must be followed by an ASCII character */ |
REG_BADPAT, /* \c must be followed by an ASCII character */ |
| 155 |
REG_BADPAT, /* \k is not followed by a braced, angle-bracketed, or quoted name */ |
REG_BADPAT, /* \k is not followed by a braced, angle-bracketed, or quoted name */ |
| 156 |
/* 70 */ |
/* 70 */ |
| 157 |
REG_BADPAT, /* internal error: unknown opcode in find_fixedlength() */ |
REG_BADPAT, /* internal error: unknown opcode in find_fixedlength() */ |
| 158 |
|
REG_BADPAT, /* \N is not supported in a class */ |
| 159 |
|
REG_BADPAT, /* too many forward references */ |
| 160 |
|
REG_BADPAT, /* disallowed UTF-8/16 code point (>= 0xd800 && <= 0xdfff) */ |
| 161 |
}; |
}; |
| 162 |
|
|
| 163 |
/* Table of texts corresponding to POSIX error codes */ |
/* Table of texts corresponding to POSIX error codes */ |
| 228 |
PCREPOSIX_EXP_DEFN void PCRE_CALL_CONVENTION |
PCREPOSIX_EXP_DEFN void PCRE_CALL_CONVENTION |
| 229 |
regfree(regex_t *preg) |
regfree(regex_t *preg) |
| 230 |
{ |
{ |
| 231 |
(pcre_free)(preg->re_pcre); |
(PUBL(free))(preg->re_pcre); |
| 232 |
} |
} |
| 233 |
|
|
| 234 |
|
|
| 277 |
eint[errorcode] : REG_BADPAT; |
eint[errorcode] : REG_BADPAT; |
| 278 |
} |
} |
| 279 |
|
|
| 280 |
preg->re_nsub = pcre_info((const pcre *)preg->re_pcre, NULL, NULL); |
(void)pcre_fullinfo((const pcre *)preg->re_pcre, NULL, PCRE_INFO_CAPTURECOUNT, |
| 281 |
|
&(preg->re_nsub)); |
| 282 |
return 0; |
return 0; |
| 283 |
} |
} |
| 284 |
|
|
| 404 |
case PCRE_ERROR_MATCHLIMIT: return REG_ESPACE; |
case PCRE_ERROR_MATCHLIMIT: return REG_ESPACE; |
| 405 |
case PCRE_ERROR_BADUTF8: return REG_INVARG; |
case PCRE_ERROR_BADUTF8: return REG_INVARG; |
| 406 |
case PCRE_ERROR_BADUTF8_OFFSET: return REG_INVARG; |
case PCRE_ERROR_BADUTF8_OFFSET: return REG_INVARG; |
| 407 |
|
case PCRE_ERROR_BADMODE: return REG_INVARG; |
| 408 |
default: return REG_ASSERT; |
default: return REG_ASSERT; |
| 409 |
} |
} |
| 410 |
} |
} |