summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2016-09-21 03:39:33 (GMT)
committerBenjamin Peterson <benjamin@python.org>2016-09-21 03:39:33 (GMT)
commit0c21214f3e583d541227df2239de377e796b55fa (patch)
tree154bfb91be848e117f6721523750bdc4afff8b71 /Objects
parentec2319c46d11e8f486e7def785339af5415a3559 (diff)
downloadcpython-0c21214f3e583d541227df2239de377e796b55fa.zip
cpython-0c21214f3e583d541227df2239de377e796b55fa.tar.gz
cpython-0c21214f3e583d541227df2239de377e796b55fa.tar.bz2
replace usage of Py_VA_COPY with the (C99) standard va_copy
Diffstat (limited to 'Objects')
-rw-r--r--Objects/abstract.c2
-rw-r--r--Objects/unicodeobject.c5
2 files changed, 3 insertions, 4 deletions
diff --git a/Objects/abstract.c b/Objects/abstract.c
index 36f2242..c6c957b 100644
--- a/Objects/abstract.c
+++ b/Objects/abstract.c
@@ -2683,7 +2683,7 @@ objargs_mkstack(PyObject **small_stack, Py_ssize_t small_stack_size,
PyObject **stack;
/* Count the number of arguments */
- Py_VA_COPY(countva, va);
+ va_copy(countva, va);
n = 0;
while (1) {
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
index 85cdbb7..f0a9083 100644
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -2874,9 +2874,8 @@ PyUnicode_FromFormatV(const char *format, va_list vargs)
writer.min_length = strlen(format) + 100;
writer.overallocate = 1;
- /* va_list may be an array (of 1 item) on some platforms (ex: AMD64).
- Copy it to be able to pass a reference to a subfunction. */
- Py_VA_COPY(vargs2, vargs);
+ // Copy varags to be able to pass a reference to a subfunction.
+ va_copy(vargs2, vargs);
for (f = format; *f; ) {
if (*f == '%') {