Mercurial > pytave
diff oct-py-types.h @ 342:6bd8f5e3542a
Convert Octave cell array into Python tuple instead of list
* oct-py-types.cc, oct-py-types.h (pytave::make_py_tuple): Rename from
pytave::make_py_list, construct a tuple instead of list.
* octave_to_python.cc (pytave::octvalue_to_pyobj): Call make_py_tuple.
author | Mike Miller <mtmiller@octave.org> |
---|---|
date | Tue, 16 Aug 2016 12:57:07 -0700 |
parents | 06b8aeea456f |
children | 9d95f087e5aa |
line wrap: on
line diff
--- a/oct-py-types.h Tue Aug 16 00:31:22 2016 -0700 +++ b/oct-py-types.h Tue Aug 16 12:57:07 2016 -0700 @@ -121,15 +121,15 @@ PyObject * make_py_int (uint64_t value); -//! Create a Python list object from the given Octave cell array value. +//! Create a Python tuple object from the given Octave cell array value. //! //! The values contained in the cell array are recursively converted to //! appropriate Python values. //! //! @param cell Octave cell array -//! @return Python list object +//! @return Python tuple object PyObject * -make_py_list (const Cell& cell); +make_py_tuple (const Cell& cell); //! Create a Python numeric object from the given Octave numeric or boolean //! scalar value.