mirror of
https://github.com/python/cpython.git
synced 2025-08-30 21:48:47 +00:00
Issue #28701: Replace PyUnicode_CompareWithASCIIString with _PyUnicode_EqualToASCIIString.
The latter function is more readable, faster and doesn't raise exceptions.
This commit is contained in:
parent
5ebff7b300
commit
f4934ea77d
21 changed files with 120 additions and 75 deletions
|
@ -1216,7 +1216,7 @@ static int pysqlite_connection_set_isolation_level(pysqlite_Connection* self, Py
|
|||
return -1;
|
||||
}
|
||||
for (candidate = begin_statements; *candidate; candidate++) {
|
||||
if (!PyUnicode_CompareWithASCIIString(uppercase_level, *candidate + 6))
|
||||
if (_PyUnicode_EqualToASCIIString(uppercase_level, *candidate + 6))
|
||||
break;
|
||||
}
|
||||
Py_DECREF(uppercase_level);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue