diff options
author | Pauli Virtanen <pav@iki.fi> | 2010-07-09 08:11:39 +0000 |
---|---|---|
committer | Pauli Virtanen <pav@iki.fi> | 2010-07-09 08:11:39 +0000 |
commit | 237ed35fd848dc5a312e15206b4d729cd2e91f90 (patch) | |
tree | 7759d771b07dbc0c1563dc7c0e2a8cbca5c88060 /numpy/random/mtrand | |
parent | 8bb282307481e208f972a72c5745c63e2404cd66 (diff) | |
download | numpy-237ed35fd848dc5a312e15206b4d729cd2e91f90.tar.gz |
BUG: random: accept Python long as input to np.random.permutation (#1535)
Diffstat (limited to 'numpy/random/mtrand')
-rw-r--r-- | numpy/random/mtrand/mtrand.pyx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/random/mtrand/mtrand.pyx b/numpy/random/mtrand/mtrand.pyx index 0340bef62..13aa111b2 100644 --- a/numpy/random/mtrand/mtrand.pyx +++ b/numpy/random/mtrand/mtrand.pyx @@ -4226,7 +4226,7 @@ cdef class RandomState: array([15, 1, 9, 4, 12]) """ - if isinstance(x, (int, np.integer)): + if isinstance(x, (int, long, np.integer)): arr = np.arange(x) else: arr = np.array(x) |