8000 Minor changes · python/cpython@308d608 · GitHub
[go: up one dir, main page]

Skip to content

Commit 308d608

Browse files
committed
Minor changes
1 parent 0106cd5 commit 308d608

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Include/cpython/unicodeobject.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,7 @@ PyAPI_FUNC(int) PyUnicodeWriter_WriteSubstring(
471471
PyUnicodeWriter *writer,
472472
PyObject *str,
473473
Py_ssize_t start,
474-
Py_ssize_t stop);
474+
Py_ssize_t end);
475475
PyAPI_FUNC(int) PyUnicodeWriter_Format(
476476
PyUnicodeWriter *writer,
477477
const char *format,

Objects/unicodeobject.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13214,7 +13214,7 @@ PyUnicodeWriter*
1321413214
PyUnicodeWriter_Create(void)
1321513215
{
1321613216
const size_t size = sizeof(_PyUnicodeWriter);
13217-
PyUnicodeWriter *writer = PyMem_Malloc(size);
13217+
PyUnicodeWriter *writer = (PyUnicodeWriter *)PyMem_Malloc(size);
1321813218
if (writer == NULL) {
1321913219
PyErr_NoMemory();
1322013220
return NULL;
@@ -13246,7 +13246,7 @@ _PyUnicodeWriter_InitWithBuffer(_PyUnicodeWriter *writer, PyObject *buffer)
1324613246
void
1324713247
PyUnicodeWriter_SetOverallocate(PyUnicodeWriter *writer, int overallocate)
1324813248
{
13249-
((_PyUnicodeWriter*)writer)->overallocate = overallocate;
13249+
((_PyUnicodeWriter*)writer)->overallocate = (unsigned char)overallocate;
1325013250
}
1325113251

1325213252

0 commit comments

Comments
 (0)
0