File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -237,6 +237,9 @@ PyBytesWriter
237237
238238 Create a :c:type: `PyBytesWriter ` to write *alloc * bytes.
239239
240+ If *alloc * is greater than zero, allocate *alloc * bytes for the returned
241+ buffer.
242+
240243 On success, return non-``NULL `` buffer where bytes can be written.
241244 On error, set an exception and return ``NULL ``.
242245
@@ -259,7 +262,9 @@ PyBytesWriter
259262
260263.. c :function :: void * PyBytesWriter_Extend (PyBytesWriter *writer, void *buf, Py_ssize_t extend)
261264
262- Extend the buffer by *extend * bytes.
265+ Add *extend * bytes to the buffer: allocate *extend * bytes in addition to
266+ bytes already allocated by previous :c:func: `PyBytesWriter_Create ` and
267+ :c:func: `PyBytesWriter_Extend ` calls.
263268
264269 On success, return non-``NULL `` buffer where bytes can be written.
265270 On error, set an exception and return ``NULL ``.
You can’t perform that action at this time.
0 commit comments