fix parsing numlist flag if objects are integers

This commit is contained in:
Christopher Lackner 2019-11-21 17:46:39 +01:00
parent 0ee5abacb2
commit e84e4f155c

View File

@ -39,7 +39,7 @@ namespace ngcore
auto vdl = py::cast<py::list>(value);
if (py::len(vdl) > 0)
{
if(py::isinstance<double>(vdl[0]))
if(py::isinstance<py::float_>(vdl[0]) || py::isinstance<py::int_>(vdl[0]))
flags.SetFlag(s, makeCArray<double>(vdl));
if(py::isinstance<py::str>(vdl[0]))
flags.SetFlag(s, makeCArray<string>(vdl));