diff options
author | orivej <orivej@yandex-team.ru> | 2022-02-10 16:44:49 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:44:49 +0300 |
commit | 718c552901d703c502ccbefdfc3c9028d608b947 (patch) | |
tree | 46534a98bbefcd7b1f3faa5b52c138ab27db75b7 /contrib/tools/python/src/Include/unicodeobject.h | |
parent | e9656aae26e0358d5378e5b63dcac5c8dbe0e4d0 (diff) | |
download | ydb-718c552901d703c502ccbefdfc3c9028d608b947.tar.gz |
Restoring authorship annotation for <orivej@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'contrib/tools/python/src/Include/unicodeobject.h')
-rw-r--r-- | contrib/tools/python/src/Include/unicodeobject.h | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/contrib/tools/python/src/Include/unicodeobject.h b/contrib/tools/python/src/Include/unicodeobject.h index 94419760c5..0f1cb6b250 100644 --- a/contrib/tools/python/src/Include/unicodeobject.h +++ b/contrib/tools/python/src/Include/unicodeobject.h @@ -67,10 +67,10 @@ Copyright (c) Corporation for National Research Initiatives. #else -#undef Py_UNICODE_SIZE -#undef PY_UNICODE_TYPE -#define Py_UNICODE_SIZE ARCADIA_PYTHON_UNICODE_SIZE - +#undef Py_UNICODE_SIZE +#undef PY_UNICODE_TYPE +#define Py_UNICODE_SIZE ARCADIA_PYTHON_UNICODE_SIZE + /* FIXME: MvL's new implementation assumes that Py_UNICODE_SIZE is properly set, but the default rules below doesn't set it. I'll sort this out some other day -- fredrik@pythonware.com */ @@ -106,10 +106,10 @@ Copyright (c) Corporation for National Research Initiatives. #endif -#ifndef PY_UNICODE_TYPE -#define PY_UNICODE_TYPE unsigned short -#endif - +#ifndef PY_UNICODE_TYPE +#define PY_UNICODE_TYPE unsigned short +#endif + /* If the compiler provides a wchar_t type we try to support it through the interface functions PyUnicode_FromWideChar() and PyUnicode_AsWideChar(). */ @@ -403,7 +403,7 @@ typedef PY_UNICODE_TYPE Py_UNICODE; #define Py_UNICODE_FILL(target, value, length) \ do {Py_ssize_t i_; Py_UNICODE *t_ = (target); Py_UNICODE v_ = (value);\ - for (i_ = 0; i_ < (length); i_++) t_[i_] = v_;\ + for (i_ = 0; i_ < (length); i_++) t_[i_] = v_;\ } while (0) /* Check if substring matches at given offset. the offset must be @@ -521,7 +521,7 @@ PyAPI_FUNC(int) PyUnicode_Resize( Py_ssize_t length /* New length */ ); -/* Coerce obj to a Unicode object and return a reference with +/* Coerce obj to a Unicode object and return a reference with *incremented* refcount. Coercion is done in the following way: @@ -544,7 +544,7 @@ PyAPI_FUNC(PyObject*) PyUnicode_FromEncodedObject( const char *errors /* error handling */ ); -/* Coerce obj to a Unicode object and return a reference with +/* Coerce obj to a Unicode object and return a reference with *incremented* refcount. Unicode objects are passed back as-is (subclasses are converted to @@ -1146,7 +1146,7 @@ PyAPI_FUNC(int) PyUnicode_EncodeDecimal( These are capable of handling Unicode objects and strings on input (we refer to them as strings in the descriptions) and return - Unicode objects or integers as appropriate. */ + Unicode objects or integers as appropriate. */ /* Concat two strings giving a new Unicode string. */ @@ -1296,7 +1296,7 @@ PyAPI_FUNC(int) PyUnicode_Compare( /* Rich compare two strings and return one of the following: - NULL in case an exception was raised - - Py_True or Py_False for successful comparisons + - Py_True or Py_False for successful comparisons - Py_NotImplemented in case the type combination is unknown Note that Py_EQ and Py_NE comparisons can cause a UnicodeWarning in @@ -1315,7 +1315,7 @@ PyAPI_FUNC(PyObject *) PyUnicode_RichCompare( int op /* Operation: Py_EQ, Py_NE, Py_GT, etc. */ ); -/* Apply an argument tuple or dictionary to a format string and return +/* Apply an argument tuple or dictionary to a format string and return the resulting Unicode string. */ PyAPI_FUNC(PyObject *) PyUnicode_Format( @@ -1326,7 +1326,7 @@ PyAPI_FUNC(PyObject *) PyUnicode_Format( /* Checks whether element is contained in container and return 1/0 accordingly. - element has to coerce to a one element Unicode string. -1 is + element has to coerce to a one element Unicode string. -1 is returned in case of an error. */ PyAPI_FUNC(int) PyUnicode_Contains( |