Home
last modified time | relevance | path

Searched refs:py_val (Results 1 – 5 of 5) sorted by relevance

/external/python/cpython2/Modules/_sqlite/
Dutil.c139 _pysqlite_long_as_int64(PyObject * py_val) in _pysqlite_long_as_int64() argument
143 PY_LONG_LONG value = PyLong_AsLongLongAndOverflow(py_val, &overflow); in _pysqlite_long_as_int64()
145 long value = PyLong_AsLongAndOverflow(py_val, &overflow); in _pysqlite_long_as_int64()
163 if (_PyLong_AsByteArray((PyLongObject *)py_val, in _pysqlite_long_as_int64()
Dconnection.c551 _pysqlite_set_result(sqlite3_context* context, PyObject* py_val) in _pysqlite_set_result() argument
553 if (py_val == Py_None) { in _pysqlite_set_result()
555 } else if (PyInt_Check(py_val)) { in _pysqlite_set_result()
556 sqlite3_result_int64(context, (sqlite_int64)PyInt_AsLong(py_val)); in _pysqlite_set_result()
557 } else if (PyLong_Check(py_val)) { in _pysqlite_set_result()
558 sqlite_int64 value = _pysqlite_long_as_int64(py_val); in _pysqlite_set_result()
562 } else if (PyFloat_Check(py_val)) { in _pysqlite_set_result()
563 sqlite3_result_double(context, PyFloat_AsDouble(py_val)); in _pysqlite_set_result()
564 } else if (PyBuffer_Check(py_val)) { in _pysqlite_set_result()
567 if (PyObject_AsCharBuffer(py_val, &buffer, &buflen) != 0) { in _pysqlite_set_result()
[all …]
/external/python/cpython3/Modules/_sqlite/
Dutil.c123 _pysqlite_long_as_int64(PyObject * py_val) in _pysqlite_long_as_int64() argument
126 long long value = PyLong_AsLongLongAndOverflow(py_val, &overflow); in _pysqlite_long_as_int64()
137 if (_PyLong_AsByteArray((PyLongObject *)py_val, in _pysqlite_long_as_int64()
Dconnection.c502 _pysqlite_set_result(sqlite3_context* context, PyObject* py_val) in _pysqlite_set_result() argument
504 if (py_val == Py_None) { in _pysqlite_set_result()
506 } else if (PyLong_Check(py_val)) { in _pysqlite_set_result()
507 sqlite_int64 value = _pysqlite_long_as_int64(py_val); in _pysqlite_set_result()
511 } else if (PyFloat_Check(py_val)) { in _pysqlite_set_result()
512 sqlite3_result_double(context, PyFloat_AsDouble(py_val)); in _pysqlite_set_result()
513 } else if (PyUnicode_Check(py_val)) { in _pysqlite_set_result()
514 const char *str = PyUnicode_AsUTF8(py_val); in _pysqlite_set_result()
518 } else if (PyObject_CheckBuffer(py_val)) { in _pysqlite_set_result()
520 if (PyObject_GetBuffer(py_val, &view, PyBUF_SIMPLE) != 0) { in _pysqlite_set_result()
/external/tensorflow/tensorflow/python/framework/
Dcpp_shape_inference.cc105 auto* py_val = input_constant_tensor_values[i]; in RunCppShapeInferenceImpl() local
106 if (py_val == Py_None) { in RunCppShapeInferenceImpl()
110 ConvertNdarrayToTensor(py_val, &input_tensor_values[i])); in RunCppShapeInferenceImpl()