diff options
author | Mathias Hasselmann <hasselmm@src.gnome.org> | 2007-12-13 15:08:59 +0000 |
---|---|---|
committer | Mathias Hasselmann <hasselmm@src.gnome.org> | 2007-12-13 15:08:59 +0000 |
commit | 69f071c88b21698bb9ebf53082b7155a3d141e43 (patch) | |
tree | 820b5c4fa2f3d7c4dfae6a24ff91aca779703e4f /glib/gregex.c | |
parent | 9a886dbe73c434cff3aa950cadf9a7bf490f703f (diff) | |
download | glib-69f071c88b21698bb9ebf53082b7155a3d141e43.tar.gz |
Give exmples in error message unsupported case-changing escape
sequences. (503222)
* glib/gregex.c: Add examples to error message for PCRE-ERR37.
svn path=/trunk/; revision=6113
Diffstat (limited to 'glib/gregex.c')
-rw-r--r-- | glib/gregex.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/glib/gregex.c b/glib/gregex.c index 26d89d974..fa9cefba1 100644 --- a/glib/gregex.c +++ b/glib/gregex.c @@ -189,7 +189,8 @@ translate_compile_error (gint *errcode, gchar **errmsg) * G_REGEX_ERROR_COMPILE error code in errcode and keep the * untranslated error message returned by PCRE. * Note that there can be more PCRE errors with the same GRegexError - * and that some PCRE errors are useless for us. */ + * and that some PCRE errors are useless for us. + */ *errcode += 100; switch (*errcode) @@ -204,8 +205,11 @@ translate_compile_error (gint *errcode, gchar **errmsg) *errmsg = _("unrecognized character follows \\"); break; case 137: + /* A number of Perl escapes are not handled by PCRE. + * Therefore it explicitly raises ERR37. + */ *errcode = G_REGEX_ERROR_UNRECOGNIZED_ESCAPE; - *errmsg = _("case changing escapes are not allowed here"); + *errmsg = _("case-changing escapes (\\l, \\L, \\u, \\U) are not allowed here"); break; case G_REGEX_ERROR_QUANTIFIERS_OUT_OF_ORDER: *errmsg = _("numbers out of order in {} quantifier"); |