mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
reindent, again
This commit is contained in:
parent
186d9b3b25
commit
339f8c6fe1
1 changed files with 2581 additions and 2581 deletions
|
@ -225,7 +225,7 @@ Py_LOCAL_INLINE(int) unicode_member(Py_UNICODE chr, Py_UNICODE* set, Py_ssize_t
|
|||
return 0;
|
||||
}
|
||||
|
||||
#define BLOOM_MEMBER(mask, chr, set, setlen)\
|
||||
#define BLOOM_MEMBER(mask, chr, set, setlen) \
|
||||
BLOOM(mask, chr) && unicode_member(chr, set, setlen)
|
||||
|
||||
/* --- Unicode Object ----------------------------------------------------- */
|
||||
|
@ -691,11 +691,11 @@ PyUnicode_FromFormatV(const char *format, va_list vargs)
|
|||
s++; if(!*s)break;
|
||||
s++;
|
||||
} else {
|
||||
#ifdef Py_UNICODE_WIDE
|
||||
#ifdef Py_UNICODE_WIDE
|
||||
n++;
|
||||
#else
|
||||
#else
|
||||
n+=2;
|
||||
#endif
|
||||
#endif
|
||||
s++; if(!*s)break;
|
||||
s++; if(!*s)break;
|
||||
s++; if(!*s)break;
|
||||
|
@ -1636,7 +1636,7 @@ PyObject *PyUnicode_DecodeUTF7Stateful(const char *s,
|
|||
Py_XDECREF(exc);
|
||||
return (PyObject *)unicode;
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_XDECREF(errorHandler);
|
||||
Py_XDECREF(exc);
|
||||
Py_DECREF(unicode);
|
||||
|
@ -1958,7 +1958,7 @@ PyObject *PyUnicode_DecodeUTF8Stateful(const char *s,
|
|||
Py_XDECREF(exc);
|
||||
return (PyObject *)unicode;
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_XDECREF(errorHandler);
|
||||
Py_XDECREF(exc);
|
||||
Py_DECREF(unicode);
|
||||
|
@ -2039,7 +2039,7 @@ PyUnicode_EncodeUTF8(const Py_UNICODE *s,
|
|||
*p++ = (char)(0x80 | (ch & 0x3f));
|
||||
continue;
|
||||
}
|
||||
encodeUCS4:
|
||||
encodeUCS4:
|
||||
/* Encode UCS4 Unicode ordinals */
|
||||
*p++ = (char)(0xf0 | (ch >> 18));
|
||||
*p++ = (char)(0x80 | ((ch >> 12) & 0x3f));
|
||||
|
@ -2242,7 +2242,7 @@ PyUnicode_DecodeUTF32Stateful(const char *s,
|
|||
Py_XDECREF(exc);
|
||||
return (PyObject *)unicode;
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_DECREF(unicode);
|
||||
Py_XDECREF(errorHandler);
|
||||
Py_XDECREF(exc);
|
||||
|
@ -2516,7 +2516,7 @@ PyUnicode_DecodeUTF16Stateful(const char *s,
|
|||
Py_XDECREF(exc);
|
||||
return (PyObject *)unicode;
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_DECREF(unicode);
|
||||
Py_XDECREF(errorHandler);
|
||||
Py_XDECREF(exc);
|
||||
|
@ -2844,7 +2844,7 @@ PyObject *PyUnicode_DecodeUnicodeEscape(const char *s,
|
|||
Py_XDECREF(exc);
|
||||
return (PyObject *)v;
|
||||
|
||||
ucnhashError:
|
||||
ucnhashError:
|
||||
PyErr_SetString(
|
||||
PyExc_UnicodeError,
|
||||
"\\N escapes not supported (can't load unicodedata module)"
|
||||
|
@ -2854,7 +2854,7 @@ ucnhashError:
|
|||
Py_XDECREF(exc);
|
||||
return NULL;
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_XDECREF(v);
|
||||
Py_XDECREF(errorHandler);
|
||||
Py_XDECREF(exc);
|
||||
|
@ -3297,9 +3297,9 @@ PyObject *_PyUnicode_DecodeUnicodeInternal(const char *s,
|
|||
/* We have to sanity check the raw data, otherwise doom looms for
|
||||
some malformed UCS-4 data. */
|
||||
if (
|
||||
#ifdef Py_UNICODE_WIDE
|
||||
#ifdef Py_UNICODE_WIDE
|
||||
*p > unimax || *p < 0 ||
|
||||
#endif
|
||||
#endif
|
||||
end-s < Py_UNICODE_SIZE
|
||||
)
|
||||
{
|
||||
|
@ -4213,9 +4213,9 @@ PyUnicode_BuildEncodingMap(PyObject* string)
|
|||
for (i = 1; i < 256; i++) {
|
||||
int l1, l2;
|
||||
if (decode[i] == 0
|
||||
#ifdef Py_UNICODE_WIDE
|
||||
#ifdef Py_UNICODE_WIDE
|
||||
|| decode[i] > 0xFFFF
|
||||
#endif
|
||||
#endif
|
||||
) {
|
||||
need_dict = 1;
|
||||
break;
|
||||
|
@ -4786,8 +4786,8 @@ int charmaptranslate_lookup(Py_UNICODE c, PyObject *mapping, PyObject **result)
|
|||
}
|
||||
}
|
||||
/* ensure that *outobj is at least requiredsize characters long,
|
||||
if not reallocate and adjust various state variables.
|
||||
Return 0 on success, -1 on error */
|
||||
if not reallocate and adjust various state variables.
|
||||
Return 0 on success, -1 on error */
|
||||
static
|
||||
int charmaptranslate_makespace(PyObject **outobj, Py_UNICODE **outp,
|
||||
Py_ssize_t requiredsize)
|
||||
|
@ -6079,7 +6079,7 @@ PyObject *replace(PyUnicodeObject *self,
|
|||
}
|
||||
return (PyObject *) u;
|
||||
|
||||
nothing:
|
||||
nothing:
|
||||
/* nothing to replace; return original string (when possible) */
|
||||
if (PyUnicode_CheckExact(self)) {
|
||||
Py_INCREF(self);
|
||||
|
@ -6091,7 +6091,7 @@ nothing:
|
|||
/* --- Unicode Object Methods --------------------------------------------- */
|
||||
|
||||
PyDoc_STRVAR(title__doc__,
|
||||
"S.title() -> unicode\n\
|
||||
"S.title() -> unicode\n\
|
||||
\n\
|
||||
Return a titlecased version of S, i.e. words start with title case\n\
|
||||
characters, all remaining cased characters have lower case.");
|
||||
|
@ -6103,7 +6103,7 @@ unicode_title(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(capitalize__doc__,
|
||||
"S.capitalize() -> unicode\n\
|
||||
"S.capitalize() -> unicode\n\
|
||||
\n\
|
||||
Return a capitalized version of S, i.e. make the first character\n\
|
||||
have upper case.");
|
||||
|
@ -6116,7 +6116,7 @@ unicode_capitalize(PyUnicodeObject *self)
|
|||
|
||||
#if 0
|
||||
PyDoc_STRVAR(capwords__doc__,
|
||||
"S.capwords() -> unicode\n\
|
||||
"S.capwords() -> unicode\n\
|
||||
\n\
|
||||
Apply .capitalize() to all words in S and return the result with\n\
|
||||
normalized whitespace (all whitespace strings are replaced by ' ').");
|
||||
|
@ -6146,7 +6146,7 @@ unicode_capwords(PyUnicodeObject *self)
|
|||
/* Join the words to form a new string */
|
||||
item = PyUnicode_Join(NULL, list);
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_DECREF(list);
|
||||
return (PyObject *)item;
|
||||
}
|
||||
|
@ -6180,7 +6180,7 @@ convert_uc(PyObject *obj, void *addr)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(center__doc__,
|
||||
"S.center(width[, fillchar]) -> unicode\n\
|
||||
"S.center(width[, fillchar]) -> unicode\n\
|
||||
\n\
|
||||
Return S centered in a Unicode string of length width. Padding is\n\
|
||||
done using the specified fill character (default is a space)");
|
||||
|
@ -6313,7 +6313,7 @@ int PyUnicode_Compare(PyObject *left,
|
|||
Py_DECREF(v);
|
||||
return result;
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_XDECREF(u);
|
||||
Py_XDECREF(v);
|
||||
return -1;
|
||||
|
@ -6459,14 +6459,14 @@ PyObject *PyUnicode_Concat(PyObject *left,
|
|||
Py_DECREF(v);
|
||||
return (PyObject *)w;
|
||||
|
||||
onError:
|
||||
onError:
|
||||
Py_XDECREF(u);
|
||||
Py_XDECREF(v);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
PyDoc_STRVAR(count__doc__,
|
||||
"S.count(sub[, start[, end]]) -> int\n\
|
||||
"S.count(sub[, start[, end]]) -> int\n\
|
||||
\n\
|
||||
Return the number of non-overlapping occurrences of substring sub in\n\
|
||||
Unicode string S[start:end]. Optional arguments start and end are\n\
|
||||
|
@ -6502,7 +6502,7 @@ unicode_count(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(encode__doc__,
|
||||
"S.encode([encoding[,errors]]) -> string or unicode\n\
|
||||
"S.encode([encoding[,errors]]) -> string or unicode\n\
|
||||
\n\
|
||||
Encodes S using the codec registered for encoding. encoding defaults\n\
|
||||
to the default encoding. errors may be given to set a different error\n\
|
||||
|
@ -6538,7 +6538,7 @@ unicode_encode(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(decode__doc__,
|
||||
"S.decode([encoding[,errors]]) -> string or unicode\n\
|
||||
"S.decode([encoding[,errors]]) -> string or unicode\n\
|
||||
\n\
|
||||
Decodes S using the codec registered for encoding. encoding defaults\n\
|
||||
to the default encoding. errors may be given to set a different error\n\
|
||||
|
@ -6574,7 +6574,7 @@ unicode_decode(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(expandtabs__doc__,
|
||||
"S.expandtabs([tabsize]) -> unicode\n\
|
||||
"S.expandtabs([tabsize]) -> unicode\n\
|
||||
\n\
|
||||
Return a copy of S where all tab characters are expanded using spaces.\n\
|
||||
If tabsize is not given, a tab size of 8 characters is assumed.");
|
||||
|
@ -6661,7 +6661,7 @@ unicode_expandtabs(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(find__doc__,
|
||||
"S.find(sub [,start [,end]]) -> int\n\
|
||||
"S.find(sub [,start [,end]]) -> int\n\
|
||||
\n\
|
||||
Return the lowest index in S where substring sub is found,\n\
|
||||
such that sub is contained within s[start:end]. Optional\n\
|
||||
|
@ -6730,7 +6730,7 @@ unicode_hash(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(index__doc__,
|
||||
"S.index(sub [,start [,end]]) -> int\n\
|
||||
"S.index(sub [,start [,end]]) -> int\n\
|
||||
\n\
|
||||
Like S.find() but raise ValueError when the substring is not found.");
|
||||
|
||||
|
@ -6762,7 +6762,7 @@ unicode_index(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(islower__doc__,
|
||||
"S.islower() -> bool\n\
|
||||
"S.islower() -> bool\n\
|
||||
\n\
|
||||
Return True if all cased characters in S are lowercase and there is\n\
|
||||
at least one cased character in S, False otherwise.");
|
||||
|
@ -6796,7 +6796,7 @@ unicode_islower(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(isupper__doc__,
|
||||
"S.isupper() -> bool\n\
|
||||
"S.isupper() -> bool\n\
|
||||
\n\
|
||||
Return True if all cased characters in S are uppercase and there is\n\
|
||||
at least one cased character in S, False otherwise.");
|
||||
|
@ -6830,7 +6830,7 @@ unicode_isupper(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(istitle__doc__,
|
||||
"S.istitle() -> bool\n\
|
||||
"S.istitle() -> bool\n\
|
||||
\n\
|
||||
Return True if S is a titlecased string and there is at least one\n\
|
||||
character in S, i.e. upper- and titlecase characters may only\n\
|
||||
|
@ -6878,7 +6878,7 @@ unicode_istitle(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(isspace__doc__,
|
||||
"S.isspace() -> bool\n\
|
||||
"S.isspace() -> bool\n\
|
||||
\n\
|
||||
Return True if all characters in S are whitespace\n\
|
||||
and there is at least one character in S, False otherwise.");
|
||||
|
@ -6907,7 +6907,7 @@ unicode_isspace(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(isalpha__doc__,
|
||||
"S.isalpha() -> bool\n\
|
||||
"S.isalpha() -> bool\n\
|
||||
\n\
|
||||
Return True if all characters in S are alphabetic\n\
|
||||
and there is at least one character in S, False otherwise.");
|
||||
|
@ -6936,7 +6936,7 @@ unicode_isalpha(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(isalnum__doc__,
|
||||
"S.isalnum() -> bool\n\
|
||||
"S.isalnum() -> bool\n\
|
||||
\n\
|
||||
Return True if all characters in S are alphanumeric\n\
|
||||
and there is at least one character in S, False otherwise.");
|
||||
|
@ -6965,7 +6965,7 @@ unicode_isalnum(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(isdecimal__doc__,
|
||||
"S.isdecimal() -> bool\n\
|
||||
"S.isdecimal() -> bool\n\
|
||||
\n\
|
||||
Return True if there are only decimal characters in S,\n\
|
||||
False otherwise.");
|
||||
|
@ -6994,7 +6994,7 @@ unicode_isdecimal(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(isdigit__doc__,
|
||||
"S.isdigit() -> bool\n\
|
||||
"S.isdigit() -> bool\n\
|
||||
\n\
|
||||
Return True if all characters in S are digits\n\
|
||||
and there is at least one character in S, False otherwise.");
|
||||
|
@ -7023,7 +7023,7 @@ unicode_isdigit(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(isnumeric__doc__,
|
||||
"S.isnumeric() -> bool\n\
|
||||
"S.isnumeric() -> bool\n\
|
||||
\n\
|
||||
Return True if there are only numeric characters in S,\n\
|
||||
False otherwise.");
|
||||
|
@ -7052,7 +7052,7 @@ unicode_isnumeric(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(join__doc__,
|
||||
"S.join(sequence) -> unicode\n\
|
||||
"S.join(sequence) -> unicode\n\
|
||||
\n\
|
||||
Return a string which is the concatenation of the strings in the\n\
|
||||
sequence. The separator between elements is S.");
|
||||
|
@ -7070,7 +7070,7 @@ unicode_length(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(ljust__doc__,
|
||||
"S.ljust(width[, fillchar]) -> int\n\
|
||||
"S.ljust(width[, fillchar]) -> int\n\
|
||||
\n\
|
||||
Return S left-justified in a Unicode string of length width. Padding is\n\
|
||||
done using the specified fill character (default is a space).");
|
||||
|
@ -7093,7 +7093,7 @@ unicode_ljust(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(lower__doc__,
|
||||
"S.lower() -> unicode\n\
|
||||
"S.lower() -> unicode\n\
|
||||
\n\
|
||||
Return a copy of the string S converted to lowercase.");
|
||||
|
||||
|
@ -7211,7 +7211,7 @@ do_argstrip(PyUnicodeObject *self, int striptype, PyObject *args)
|
|||
|
||||
|
||||
PyDoc_STRVAR(strip__doc__,
|
||||
"S.strip([chars]) -> unicode\n\
|
||||
"S.strip([chars]) -> unicode\n\
|
||||
\n\
|
||||
Return a copy of the string S with leading and trailing\n\
|
||||
whitespace removed.\n\
|
||||
|
@ -7229,7 +7229,7 @@ unicode_strip(PyUnicodeObject *self, PyObject *args)
|
|||
|
||||
|
||||
PyDoc_STRVAR(lstrip__doc__,
|
||||
"S.lstrip([chars]) -> unicode\n\
|
||||
"S.lstrip([chars]) -> unicode\n\
|
||||
\n\
|
||||
Return a copy of the string S with leading whitespace removed.\n\
|
||||
If chars is given and not None, remove characters in chars instead.\n\
|
||||
|
@ -7246,7 +7246,7 @@ unicode_lstrip(PyUnicodeObject *self, PyObject *args)
|
|||
|
||||
|
||||
PyDoc_STRVAR(rstrip__doc__,
|
||||
"S.rstrip([chars]) -> unicode\n\
|
||||
"S.rstrip([chars]) -> unicode\n\
|
||||
\n\
|
||||
Return a copy of the string S with trailing whitespace removed.\n\
|
||||
If chars is given and not None, remove characters in chars instead.\n\
|
||||
|
@ -7353,7 +7353,7 @@ PyObject *PyUnicode_Replace(PyObject *obj,
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(replace__doc__,
|
||||
"S.replace (old, new[, count]) -> unicode\n\
|
||||
"S.replace (old, new[, count]) -> unicode\n\
|
||||
\n\
|
||||
Return a copy of S with all occurrences of substring\n\
|
||||
old replaced by new. If the optional argument count is\n\
|
||||
|
@ -7394,7 +7394,7 @@ PyObject *unicode_repr(PyObject *unicode)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(rfind__doc__,
|
||||
"S.rfind(sub [,start [,end]]) -> int\n\
|
||||
"S.rfind(sub [,start [,end]]) -> int\n\
|
||||
\n\
|
||||
Return the highest index in S where substring sub is found,\n\
|
||||
such that sub is contained within s[start:end]. Optional\n\
|
||||
|
@ -7425,7 +7425,7 @@ unicode_rfind(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(rindex__doc__,
|
||||
"S.rindex(sub [,start [,end]]) -> int\n\
|
||||
"S.rindex(sub [,start [,end]]) -> int\n\
|
||||
\n\
|
||||
Like S.rfind() but raise ValueError when the substring is not found.");
|
||||
|
||||
|
@ -7456,7 +7456,7 @@ unicode_rindex(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(rjust__doc__,
|
||||
"S.rjust(width[, fillchar]) -> unicode\n\
|
||||
"S.rjust(width[, fillchar]) -> unicode\n\
|
||||
\n\
|
||||
Return S right-justified in a Unicode string of length width. Padding is\n\
|
||||
done using the specified fill character (default is a space).");
|
||||
|
@ -7525,7 +7525,7 @@ PyObject *PyUnicode_Split(PyObject *s,
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(split__doc__,
|
||||
"S.split([sep [,maxsplit]]) -> list of strings\n\
|
||||
"S.split([sep [,maxsplit]]) -> list of strings\n\
|
||||
\n\
|
||||
Return a list of the words in S, using sep as the\n\
|
||||
delimiter string. If maxsplit is given, at most maxsplit\n\
|
||||
|
@ -7606,7 +7606,7 @@ PyUnicode_RPartition(PyObject *str_in, PyObject *sep_in)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(partition__doc__,
|
||||
"S.partition(sep) -> (head, sep, tail)\n\
|
||||
"S.partition(sep) -> (head, sep, tail)\n\
|
||||
\n\
|
||||
Search for the separator sep in S, and return the part before it,\n\
|
||||
the separator itself, and the part after it. If the separator is not\n\
|
||||
|
@ -7619,7 +7619,7 @@ unicode_partition(PyUnicodeObject *self, PyObject *separator)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(rpartition__doc__,
|
||||
"S.rpartition(sep) -> (tail, sep, head)\n\
|
||||
"S.rpartition(sep) -> (tail, sep, head)\n\
|
||||
\n\
|
||||
Search for the separator sep in S, starting at the end of S, and return\n\
|
||||
the part before it, the separator itself, and the part after it. If the\n\
|
||||
|
@ -7656,7 +7656,7 @@ PyObject *PyUnicode_RSplit(PyObject *s,
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(rsplit__doc__,
|
||||
"S.rsplit([sep [,maxsplit]]) -> list of strings\n\
|
||||
"S.rsplit([sep [,maxsplit]]) -> list of strings\n\
|
||||
\n\
|
||||
Return a list of the words in S, using sep as the\n\
|
||||
delimiter string, starting at the end of the string and\n\
|
||||
|
@ -7682,7 +7682,7 @@ unicode_rsplit(PyUnicodeObject *self, PyObject *args)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(splitlines__doc__,
|
||||
"S.splitlines([keepends]) -> list of strings\n\
|
||||
"S.splitlines([keepends]) -> list of strings\n\
|
||||
\n\
|
||||
Return a list of the lines in S, breaking at line boundaries.\n\
|
||||
Line breaks are not included in the resulting list unless keepends\n\
|
||||
|
@ -7706,7 +7706,7 @@ PyObject *unicode_str(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(swapcase__doc__,
|
||||
"S.swapcase() -> unicode\n\
|
||||
"S.swapcase() -> unicode\n\
|
||||
\n\
|
||||
Return a copy of S with uppercase characters converted to lowercase\n\
|
||||
and vice versa.");
|
||||
|
@ -7718,7 +7718,7 @@ unicode_swapcase(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(translate__doc__,
|
||||
"S.translate(table) -> unicode\n\
|
||||
"S.translate(table) -> unicode\n\
|
||||
\n\
|
||||
Return a copy of the string S, where all characters have been mapped\n\
|
||||
through the given translation table, which must be a mapping of\n\
|
||||
|
@ -7736,7 +7736,7 @@ unicode_translate(PyUnicodeObject *self, PyObject *table)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(upper__doc__,
|
||||
"S.upper() -> unicode\n\
|
||||
"S.upper() -> unicode\n\
|
||||
\n\
|
||||
Return a copy of S converted to uppercase.");
|
||||
|
||||
|
@ -7747,7 +7747,7 @@ unicode_upper(PyUnicodeObject *self)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(zfill__doc__,
|
||||
"S.zfill(width) -> unicode\n\
|
||||
"S.zfill(width) -> unicode\n\
|
||||
\n\
|
||||
Pad a numeric string S with zeros on the left, to fill a field\n\
|
||||
of the specified width. The string S is never truncated.");
|
||||
|
@ -7799,7 +7799,7 @@ free_listsize(PyUnicodeObject *self)
|
|||
#endif
|
||||
|
||||
PyDoc_STRVAR(startswith__doc__,
|
||||
"S.startswith(prefix[, start[, end]]) -> bool\n\
|
||||
"S.startswith(prefix[, start[, end]]) -> bool\n\
|
||||
\n\
|
||||
Return True if S starts with the specified prefix, False otherwise.\n\
|
||||
With optional start, test S beginning at that position.\n\
|
||||
|
@ -7845,7 +7845,7 @@ unicode_startswith(PyUnicodeObject *self,
|
|||
|
||||
|
||||
PyDoc_STRVAR(endswith__doc__,
|
||||
"S.endswith(suffix[, start[, end]]) -> bool\n\
|
||||
"S.endswith(suffix[, start[, end]]) -> bool\n\
|
||||
\n\
|
||||
Return True if S ends with the specified suffix, False otherwise.\n\
|
||||
With optional start, test S beginning at that position.\n\
|
||||
|
@ -7894,7 +7894,7 @@ unicode_endswith(PyUnicodeObject *self,
|
|||
#include "stringlib/string_format.h"
|
||||
|
||||
PyDoc_STRVAR(format__doc__,
|
||||
"S.format(*args, **kwargs) -> unicode\n\
|
||||
"S.format(*args, **kwargs) -> unicode\n\
|
||||
\n\
|
||||
");
|
||||
|
||||
|
@ -7922,13 +7922,13 @@ unicode__format__(PyObject *self, PyObject *args)
|
|||
result = _PyUnicode_FormatAdvanced(self,
|
||||
PyUnicode_AS_UNICODE(format_spec),
|
||||
PyUnicode_GET_SIZE(format_spec));
|
||||
done:
|
||||
done:
|
||||
Py_XDECREF(tmp);
|
||||
return result;
|
||||
}
|
||||
|
||||
PyDoc_STRVAR(p_format__doc__,
|
||||
"S.__format__(format_spec) -> unicode\n\
|
||||
"S.__format__(format_spec) -> unicode\n\
|
||||
\n\
|
||||
");
|
||||
|
||||
|
@ -7940,7 +7940,7 @@ unicode__sizeof__(PyUnicodeObject *v)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(sizeof__doc__,
|
||||
"S.__sizeof__() -> size of S in memory, in bytes\n\
|
||||
"S.__sizeof__() -> size of S in memory, in bytes\n\
|
||||
\n\
|
||||
");
|
||||
|
||||
|
@ -8937,7 +8937,7 @@ unicode_subtype_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
|
|||
}
|
||||
|
||||
PyDoc_STRVAR(unicode_doc,
|
||||
"unicode(string [, encoding[, errors]]) -> object\n\
|
||||
"unicode(string [, encoding[, errors]]) -> object\n\
|
||||
\n\
|
||||
Create a new Unicode object from the given encoded string.\n\
|
||||
encoding defaults to the current default string encoding.\n\
|
||||
|
@ -9071,8 +9071,8 @@ _PyUnicode_Fini(void)
|
|||
|
||||
|
||||
/*
|
||||
Local variables:
|
||||
c-basic-offset: 4
|
||||
indent-tabs-mode: nil
|
||||
End:
|
||||
Local variables:
|
||||
c-basic-offset: 4
|
||||
indent-tabs-mode: nil
|
||||
End:
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue