Change [_Py_]re_compile_pattern() to return a char*.

Since it only returns an error message (or NULL) there's no reason
for it to be unsigned char *, and various compilers like this better.
This commit is contained in:
Guido van Rossum 1997-09-03 00:47:36 +00:00
parent 5ade084902
commit d19c04a88e
3 changed files with 12 additions and 12 deletions

View file

@ -439,7 +439,7 @@ newregexobject(pattern, translate, givenpat, groupindex)
re->re_realpat = pattern;
Py_INCREF(givenpat);
re->re_givenpat = givenpat;
error = (char *)re_compile_pattern((unsigned char *)pat, size, &re->re_patbuf);
error = _Py_re_compile_pattern((unsigned char *)pat, size, &re->re_patbuf);
if (error != NULL) {
PyErr_SetString(RegexError, error);
goto finally;