From 87f47729850f0cd3f18a7c7c1edb615556956892 Mon Sep 17 00:00:00 2001 From: Zachary Turner Date: Wed, 14 Oct 2015 16:59:44 +0000 Subject: Minor cleanup on PythonDataObject constructors. Added a constructor that takes list_size for `PythonList`. Made all single-argument constructors explicit. Re-ordered constructors to be consistent with other classes. llvm-svn: 250304 --- lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp') diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp b/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp index d90e12c..1ab5e4a 100644 --- a/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp +++ b/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp @@ -378,6 +378,12 @@ PythonList::PythonList(PyInitialValue value) Reset(PyRefType::Owned, PyList_New(0)); } +PythonList::PythonList(int list_size) + : PythonObject() +{ + Reset(PyRefType::Owned, PyList_New(list_size)); +} + PythonList::PythonList(PyRefType type, PyObject *py_obj) : PythonObject() { -- cgit v1.1