summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorMark Harfouche <mark.harfouche@gmail.com>2018-01-12 09:48:56 -0800
committerMark Harfouche <mark.harfouche@gmail.com>2018-01-12 09:48:56 -0800
commit5dc1f717844723dd2524d318ae7a3ff9da7fe3e7 (patch)
tree617e4b9cda3b3773064d4567fb35781ad911a3ac /tools
parent36bc343495ef7aa45f7d8540040cb9f577ef22fa (diff)
downloadnumpy-5dc1f717844723dd2524d318ae7a3ff9da7fe3e7.tar.gz
Added types for int and uint with an explicit size.
Diffstat (limited to 'tools')
-rw-r--r--tools/swig/numpy.i11
1 files changed, 10 insertions, 1 deletions
diff --git a/tools/swig/numpy.i b/tools/swig/numpy.i
index b8fdaeb1f..5f2aa0a5d 100644
--- a/tools/swig/numpy.i
+++ b/tools/swig/numpy.i
@@ -485,7 +485,7 @@
{
int i;
int success = 1;
- int len;
+ size_t len;
char desired_dims[255] = "[";
char s[255];
char actual_dims[255] = "[";
@@ -3139,6 +3139,15 @@
%numpy_typemaps(unsigned long long, NPY_ULONGLONG, int)
%numpy_typemaps(float , NPY_FLOAT , int)
%numpy_typemaps(double , NPY_DOUBLE , int)
+%numpy_typemaps(int8_t , NPY_INT8 , int)
+%numpy_typemaps(int16_t , NPY_INT16 , int)
+%numpy_typemaps(int32_t , NPY_INT32 , int)
+%numpy_typemaps(int64_t , NPY_INT64 , int)
+%numpy_typemaps(uint8_t , NPY_UINT8 , int)
+%numpy_typemaps(uint16_t , NPY_UINT16 , int)
+%numpy_typemaps(uint32_t , NPY_UINT32 , int)
+%numpy_typemaps(uint64_t , NPY_UINT64 , int)
+
/* ***************************************************************
* The follow macro expansion does not work, because C++ bool is 4