summaryrefslogtreecommitdiffstats
path: root/Modules/_sre.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/_sre.c')
-rw-r--r--Modules/_sre.c29
1 files changed, 20 insertions, 9 deletions
diff --git a/Modules/_sre.c b/Modules/_sre.c
index afb2bce..a86c5f2 100644
--- a/Modules/_sre.c
+++ b/Modules/_sre.c
@@ -274,25 +274,35 @@ _sre_getcodesize_impl(PyObject *module)
}
/*[clinic input]
-_sre.getlower -> int
+_sre.ascii_tolower -> int
character: int
- flags: int
/
[clinic start generated code]*/
static int
-_sre_getlower_impl(PyObject *module, int character, int flags)
-/*[clinic end generated code: output=47eebc4c1214feb5 input=087d2f1c44bbca6f]*/
+_sre_ascii_tolower_impl(PyObject *module, int character)
+/*[clinic end generated code: output=228294ed6ff2a612 input=272c609b5b61f136]*/
{
- if (flags & SRE_FLAG_LOCALE)
- return sre_lower_locale(character);
- if (flags & SRE_FLAG_UNICODE)
- return sre_lower_unicode(character);
return sre_lower(character);
}
+/*[clinic input]
+_sre.unicode_tolower -> int
+
+ character: int
+ /
+
+[clinic start generated code]*/
+
+static int
+_sre_unicode_tolower_impl(PyObject *module, int character)
+/*[clinic end generated code: output=6422272d7d7fee65 input=91d708c5f3c2045a]*/
+{
+ return sre_lower_unicode(character);
+}
+
LOCAL(void)
state_reset(SRE_STATE* state)
{
@@ -2740,7 +2750,8 @@ static PyTypeObject Scanner_Type = {
static PyMethodDef _functions[] = {
_SRE_COMPILE_METHODDEF
_SRE_GETCODESIZE_METHODDEF
- _SRE_GETLOWER_METHODDEF
+ _SRE_ASCII_TOLOWER_METHODDEF
+ _SRE_UNICODE_TOLOWER_METHODDEF
{NULL, NULL}
};