[Python-checkins] cpython: make _Py_static_string_init use a designated initializer
benjamin.peterson
python-checkins at python.org
Wed Sep 7 13:33:53 EDT 2016
https://hg.python.org/cpython/rev/1b1abe815db0
changeset: 103230:1b1abe815db0
user: Benjamin Peterson <benjamin at python.org>
date: Wed Sep 07 10:33:28 2016 -0700
summary:
make _Py_static_string_init use a designated initializer
files:
Include/object.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Include/object.h b/Include/object.h
--- a/Include/object.h
+++ b/Include/object.h
@@ -144,7 +144,7 @@
PyObject *object;
} _Py_Identifier;
-#define _Py_static_string_init(value) { 0, value, 0 }
+#define _Py_static_string_init(value) { .next = NULL, .string = value, .object = NULL }
#define _Py_static_string(varname, value) static _Py_Identifier varname = _Py_static_string_init(value)
#define _Py_IDENTIFIER(varname) _Py_static_string(PyId_##varname, #varname)
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list