Typo; hypen -> hyphen

This commit is contained in:
migeed-z 2016-05-20 15:10:54 -04:00 committed by Vincent St-Amour
parent fe03198211
commit 8d082a47c6

View File

@ -1705,12 +1705,12 @@ static char *regrange(int parse_flags, char *map)
map['-'] = 1; map['-'] = 1;
} else { } else {
if (!can_range) { if (!can_range) {
FAIL("misplaced hypen within square brackets in pattern"); FAIL("misplaced hyphen within square brackets in pattern");
} else { } else {
xclass = UCHAR(regparsestr[regparse-2])+1; xclass = UCHAR(regparsestr[regparse-2])+1;
classend = UCHAR(regparsestr[regparse]); classend = UCHAR(regparsestr[regparse]);
if (classend == '-') { if (classend == '-') {
FAIL("misplaced hypen within square brackets in pattern"); FAIL("misplaced hyphen within square brackets in pattern");
} }
if ((classend == '\\') && (parse_flags & PARSE_PCRE)) { if ((classend == '\\') && (parse_flags & PARSE_PCRE)) {
if (regparse+1 == regparse_end) { if (regparse+1 == regparse_end) {
@ -1720,7 +1720,7 @@ static char *regrange(int parse_flags, char *map)
classend = UCHAR(regparsestr[regparse]); classend = UCHAR(regparsestr[regparse]);
if (((classend >= 'a') && (classend <= 'z')) if (((classend >= 'a') && (classend <= 'z'))
|| ((classend >= 'A') && (classend <= 'Z'))) { || ((classend >= 'A') && (classend <= 'Z'))) {
FAIL("misplaced hypen within square brackets in pattern"); FAIL("misplaced hyphen within square brackets in pattern");
} }
} }
if (xclass > classend+1) if (xclass > classend+1)
@ -4604,7 +4604,7 @@ static int translate(unsigned char *s, int len, char **result, int pcre)
&& (!pcre || ((us[p] != '\\') && (us[p+2] != '\\')))) { && (!pcre || ((us[p] != '\\') && (us[p+2] != '\\')))) {
int beg = us[p], end = us[p+2]; int beg = us[p], end = us[p+2];
if (end == '-') { if (end == '-') {
FAIL("misplaced hypen within square brackets in pattern"); FAIL("misplaced hyphen within square brackets in pattern");
} }
if (end < beg) { if (end < beg) {
/* Bad regexp */ /* Bad regexp */
@ -4734,7 +4734,7 @@ static int translate(unsigned char *s, int len, char **result, int pcre)
p++; p++;
} else { } else {
if (((p + 1) < ulen) && (us[p] == '-')) { if (((p + 1) < ulen) && (us[p] == '-')) {
FAIL("misplaced hypen within square brackets in pattern"); FAIL("misplaced hyphen within square brackets in pattern");
return 0; return 0;
} }
simple_on[us[p]] = 1; simple_on[us[p]] = 1;